NVIDIA / cuda-quantum

C++ and Python support for the CUDA Quantum programming model for heterogeneous quantum-classical workflows
https://nvidia.github.io/cuda-quantum/
Other
564 stars 191 forks source link

[refactoring] Move constants into a common header file #1911

Open khalatepradnya opened 4 months ago

khalatepradnya commented 4 months ago

This is exactly the reason why these strings should be in a header file and not just hard coded in random files. The latter is bad coding practice.

I thought the runtime already included files from the compiler, but maybe I am wrong about that.

Open to any suggestions on where to put universal constants, including string data.

_Originally posted by @schweitzpgi in https://github.com/NVIDIA/cuda-quantum/pull/1794#discussion_r1672470040_

ParamThakkar123 commented 4 months ago

Is anyone working on this one??

ParamThakkar123 commented 4 months ago

If not, I can take this

khalatepradnya commented 4 months ago

If not, I can take this

Thank you. I will assign this to you.

khalatepradnya commented 4 months ago

for which files this is yet to be done ??

Start with the constant strings defined in include/cudaq/Frontend/nvqpp/AttributeNames.h that are duplicated in runtime/cudaq/qis/qubit_qis.h. Refer to the link to comment in description for context.