Closed thisac closed 2 years ago
Merging #688 (d6665b6) into master (efdf123) will increase coverage by
0.00%
. The diff coverage is100.00%
.
@@ Coverage Diff @@
## master #688 +/- ##
=======================================
Coverage 98.69% 98.69%
=======================================
Files 75 75
Lines 9209 9212 +3
=======================================
+ Hits 9089 9092 +3
Misses 120 120
Impacted Files | Coverage Δ | |
---|---|---|
strawberryfields/program.py | 100.00% <100.00%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update efdf123...d6665b6. Read the comment docs.
Context: The compiler create a linked copy of the program by calling
Program._linked_copy()
, which retains the same regrefs. Since the copy is shallow, it also keeps the same TDM parameters in a TDM program. These parameters are updated by the compiler and thus changed in both the compiled program and the initial program, while the circuit is only changed in the compiled program.Description of the Change:
Program._linked_copy()
is updated to create a deep-copy of all attributes except the ones containing register references, including e.g., the TDM parameters.Benefits: The compiler actually returns a copy of the program without changing anything in the original program.
Possible Drawbacks: None
Related GitHub Issues: None