qasm-ts 2.0.0 → 2.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (365) hide show
  1. package/.github/workflows/draft-pdf.yml +24 -0
  2. package/CONTRIBUTING.md +3 -0
  3. package/LICENSE +201 -0
  4. package/dist/errors.js +9 -0
  5. package/dist/lexer.js +74 -0
  6. package/dist/main.js +82 -7
  7. package/dist/parser.js +71 -0
  8. package/dist/qasm2/ast.js +33 -0
  9. package/dist/qasm2/lexer.js +54 -1
  10. package/dist/qasm2/parser.js +51 -1
  11. package/dist/qasm2/token.js +30 -0
  12. package/dist/qasm3/lexer.js +59 -1
  13. package/dist/qasm3/parser.js +55 -2
  14. package/dist/qasm3/token.js +93 -10
  15. package/dist/version.js +17 -1
  16. package/docs/assets/hierarchy.js +1 -0
  17. package/docs/custom.css +3 -0
  18. package/docs/docs-readme.md +208 -0
  19. package/docs/index.html +17 -55
  20. package/docs/typedoc/assets/custom.css +3 -0
  21. package/docs/typedoc/assets/hierarchy.js +1 -0
  22. package/docs/{assets → typedoc/assets}/highlight.css +20 -20
  23. package/docs/{assets → typedoc/assets}/icons.js +1 -1
  24. package/docs/{assets → typedoc/assets}/icons.svg +1 -1
  25. package/docs/typedoc/assets/main.js +60 -0
  26. package/docs/typedoc/assets/navigation.js +1 -0
  27. package/docs/typedoc/assets/search.js +1 -0
  28. package/docs/typedoc/assets/style.css +1633 -0
  29. package/docs/typedoc/classes/Error_Handling.BadArgumentError.html +12 -0
  30. package/docs/typedoc/classes/Error_Handling.BadBarrierError.html +12 -0
  31. package/docs/typedoc/classes/Error_Handling.BadClassicalTypeError.html +12 -0
  32. package/docs/typedoc/classes/Error_Handling.BadConditionalError.html +12 -0
  33. package/docs/typedoc/classes/Error_Handling.BadCregError.html +12 -0
  34. package/docs/typedoc/classes/Error_Handling.BadEqualsError.html +12 -0
  35. package/docs/typedoc/classes/Error_Handling.BadExpressionError.html +12 -0
  36. package/docs/typedoc/classes/Error_Handling.BadGateError.html +12 -0
  37. package/docs/typedoc/classes/Error_Handling.BadIncludeError.html +12 -0
  38. package/docs/typedoc/classes/Error_Handling.BadLoopError.html +12 -0
  39. package/docs/typedoc/classes/Error_Handling.BadMeasurementError.html +12 -0
  40. package/docs/typedoc/classes/Error_Handling.BadParameterError.html +12 -0
  41. package/docs/typedoc/classes/Error_Handling.BadQregError.html +12 -0
  42. package/docs/typedoc/classes/Error_Handling.BadQuantumInstructionError.html +12 -0
  43. package/docs/typedoc/classes/Error_Handling.BadStringLiteralError.html +12 -0
  44. package/docs/typedoc/classes/Error_Handling.BadSubroutineError.html +12 -0
  45. package/docs/typedoc/classes/Error_Handling.MissingBraceError.html +12 -0
  46. package/docs/typedoc/classes/Error_Handling.MissingSemicolonError.html +12 -0
  47. package/docs/typedoc/classes/Error_Handling.UnsupportedOpenQASMVersionError.html +12 -0
  48. package/docs/typedoc/classes/Version_Management.OpenQASMVersion.html +16 -0
  49. package/docs/typedoc/classes/qasm2_ast.ApplyGate.html +6 -0
  50. package/docs/typedoc/classes/qasm2_ast.AstNode.html +3 -0
  51. package/docs/typedoc/classes/qasm2_ast.Barrier.html +5 -0
  52. package/docs/typedoc/classes/qasm2_ast.CReg.html +5 -0
  53. package/docs/typedoc/classes/qasm2_ast.Cos.html +3 -0
  54. package/docs/typedoc/classes/qasm2_ast.Divide.html +3 -0
  55. package/docs/typedoc/classes/qasm2_ast.Exp.html +3 -0
  56. package/docs/typedoc/classes/qasm2_ast.Gate.html +7 -0
  57. package/docs/typedoc/classes/qasm2_ast.Id.html +4 -0
  58. package/docs/typedoc/classes/qasm2_ast.If.html +6 -0
  59. package/docs/typedoc/classes/qasm2_ast.Include.html +4 -0
  60. package/docs/typedoc/classes/qasm2_ast.Ln.html +3 -0
  61. package/docs/typedoc/classes/qasm2_ast.Measure.html +7 -0
  62. package/docs/typedoc/classes/qasm2_ast.Minus.html +3 -0
  63. package/docs/typedoc/classes/qasm2_ast.NNInteger.html +4 -0
  64. package/docs/typedoc/classes/qasm2_ast.Opaque.html +6 -0
  65. package/docs/typedoc/classes/qasm2_ast.Pi.html +3 -0
  66. package/docs/typedoc/classes/qasm2_ast.Plus.html +3 -0
  67. package/docs/typedoc/classes/qasm2_ast.Power.html +3 -0
  68. package/docs/typedoc/classes/qasm2_ast.QReg.html +5 -0
  69. package/docs/typedoc/classes/qasm2_ast.Real.html +4 -0
  70. package/docs/typedoc/classes/qasm2_ast.Sin.html +3 -0
  71. package/docs/typedoc/classes/qasm2_ast.Sqrt.html +3 -0
  72. package/docs/typedoc/classes/qasm2_ast.Tan.html +3 -0
  73. package/docs/typedoc/classes/qasm2_ast.Times.html +3 -0
  74. package/docs/typedoc/classes/qasm2_ast.Variable.html +4 -0
  75. package/docs/typedoc/classes/qasm2_ast.Version.html +4 -0
  76. package/docs/typedoc/classes/qasm2_lexer.default.html +57 -0
  77. package/docs/typedoc/classes/qasm2_parser.default.html +93 -0
  78. package/docs/typedoc/classes/qasm3_ast.AliasStatement.html +5 -0
  79. package/docs/typedoc/classes/qasm3_ast.AngleType.html +4 -0
  80. package/docs/typedoc/classes/qasm3_ast.Arithmetic.html +6 -0
  81. package/docs/typedoc/classes/qasm3_ast.ArrayAccess.html +5 -0
  82. package/docs/typedoc/classes/qasm3_ast.ArrayDeclaration.html +7 -0
  83. package/docs/typedoc/classes/qasm3_ast.ArrayInitializer.html +4 -0
  84. package/docs/typedoc/classes/qasm3_ast.ArrayReference.html +5 -0
  85. package/docs/typedoc/classes/qasm3_ast.AssignmentStatement.html +5 -0
  86. package/docs/typedoc/classes/qasm3_ast.AstNode.html +3 -0
  87. package/docs/typedoc/classes/qasm3_ast.Binary.html +6 -0
  88. package/docs/typedoc/classes/qasm3_ast.BitType.html +4 -0
  89. package/docs/typedoc/classes/qasm3_ast.BitstringLiteral.html +4 -0
  90. package/docs/typedoc/classes/qasm3_ast.BoolType.html +3 -0
  91. package/docs/typedoc/classes/qasm3_ast.BooleanLiteral.html +4 -0
  92. package/docs/typedoc/classes/qasm3_ast.BoxDefinition.html +7 -0
  93. package/docs/typedoc/classes/qasm3_ast.BranchingStatement.html +8 -0
  94. package/docs/typedoc/classes/qasm3_ast.BreakStatement.html +3 -0
  95. package/docs/typedoc/classes/qasm3_ast.CalibrationGrammarDeclaration.html +6 -0
  96. package/docs/typedoc/classes/qasm3_ast.CaseStatement.html +5 -0
  97. package/docs/typedoc/classes/qasm3_ast.Cast.html +5 -0
  98. package/docs/typedoc/classes/qasm3_ast.ClassicalDeclaration.html +7 -0
  99. package/docs/typedoc/classes/qasm3_ast.ClassicalType.html +3 -0
  100. package/docs/typedoc/classes/qasm3_ast.ComplexType.html +6 -0
  101. package/docs/typedoc/classes/qasm3_ast.ContinueStatement.html +3 -0
  102. package/docs/typedoc/classes/qasm3_ast.DefaultStatement.html +4 -0
  103. package/docs/typedoc/classes/qasm3_ast.DurationLiteral.html +5 -0
  104. package/docs/typedoc/classes/qasm3_ast.DurationOf.html +4 -0
  105. package/docs/typedoc/classes/qasm3_ast.DurationType.html +3 -0
  106. package/docs/typedoc/classes/qasm3_ast.Euler.html +3 -0
  107. package/docs/typedoc/classes/qasm3_ast.Expression.html +3 -0
  108. package/docs/typedoc/classes/qasm3_ast.ExternSignature.html +8 -0
  109. package/docs/typedoc/classes/qasm3_ast.FloatLiteral.html +4 -0
  110. package/docs/typedoc/classes/qasm3_ast.FloatType.html +6 -0
  111. package/docs/typedoc/classes/qasm3_ast.ForLoopStatement.html +12 -0
  112. package/docs/typedoc/classes/qasm3_ast.HardwareQubit.html +5 -0
  113. package/docs/typedoc/classes/qasm3_ast.IODeclaration.html +5 -0
  114. package/docs/typedoc/classes/qasm3_ast.Identifier.html +4 -0
  115. package/docs/typedoc/classes/qasm3_ast.ImaginaryLiteral.html +4 -0
  116. package/docs/typedoc/classes/qasm3_ast.Include.html +6 -0
  117. package/docs/typedoc/classes/qasm3_ast.IndexSet.html +5 -0
  118. package/docs/typedoc/classes/qasm3_ast.IntType.html +4 -0
  119. package/docs/typedoc/classes/qasm3_ast.IntegerLiteral.html +4 -0
  120. package/docs/typedoc/classes/qasm3_ast.MathFunction.html +5 -0
  121. package/docs/typedoc/classes/qasm3_ast.NumericLiteral.html +4 -0
  122. package/docs/typedoc/classes/qasm3_ast.Parameters.html +4 -0
  123. package/docs/typedoc/classes/qasm3_ast.Pi.html +3 -0
  124. package/docs/typedoc/classes/qasm3_ast.ProgramBlock.html +7 -0
  125. package/docs/typedoc/classes/qasm3_ast.QuantumBarrier.html +6 -0
  126. package/docs/typedoc/classes/qasm3_ast.QuantumBlock.html +6 -0
  127. package/docs/typedoc/classes/qasm3_ast.QuantumDeclaration.html +8 -0
  128. package/docs/typedoc/classes/qasm3_ast.QuantumDelay.html +5 -0
  129. package/docs/typedoc/classes/qasm3_ast.QuantumGateCall.html +9 -0
  130. package/docs/typedoc/classes/qasm3_ast.QuantumGateDefinition.html +9 -0
  131. package/docs/typedoc/classes/qasm3_ast.QuantumGateModifier.html +5 -0
  132. package/docs/typedoc/classes/qasm3_ast.QuantumMeasurement.html +6 -0
  133. package/docs/typedoc/classes/qasm3_ast.QuantumMeasurementAssignment.html +8 -0
  134. package/docs/typedoc/classes/qasm3_ast.QuantumReset.html +4 -0
  135. package/docs/typedoc/classes/qasm3_ast.Range.html +6 -0
  136. package/docs/typedoc/classes/qasm3_ast.ReturnStatement.html +4 -0
  137. package/docs/typedoc/classes/qasm3_ast.SizeOf.html +5 -0
  138. package/docs/typedoc/classes/qasm3_ast.Statement.html +12 -0
  139. package/docs/typedoc/classes/qasm3_ast.StretchType.html +3 -0
  140. package/docs/typedoc/classes/qasm3_ast.SubroutineBlock.html +6 -0
  141. package/docs/typedoc/classes/qasm3_ast.SubroutineCall.html +5 -0
  142. package/docs/typedoc/classes/qasm3_ast.SubroutineDefinition.html +10 -0
  143. package/docs/typedoc/classes/qasm3_ast.SubscriptedIdentifier.html +5 -0
  144. package/docs/typedoc/classes/qasm3_ast.SwitchStatement.html +6 -0
  145. package/docs/typedoc/classes/qasm3_ast.Tau.html +3 -0
  146. package/docs/typedoc/classes/qasm3_ast.TrigFunction.html +5 -0
  147. package/docs/typedoc/classes/qasm3_ast.UIntType.html +4 -0
  148. package/docs/typedoc/classes/qasm3_ast.Unary.html +5 -0
  149. package/docs/typedoc/classes/qasm3_ast.Version.html +6 -0
  150. package/docs/typedoc/classes/qasm3_ast.WhileLoopStatement.html +6 -0
  151. package/docs/typedoc/classes/qasm3_lexer.default.html +71 -0
  152. package/docs/typedoc/classes/qasm3_parser.default.html +237 -0
  153. package/docs/typedoc/enums/Version_Management.OpenQASMMajorVersion.html +4 -0
  154. package/docs/typedoc/enums/qasm2_token.Token.html +42 -0
  155. package/docs/typedoc/enums/qasm3_ast.ArithmeticOp.html +9 -0
  156. package/docs/typedoc/enums/qasm3_ast.ArrayReferenceModifier.html +4 -0
  157. package/docs/typedoc/enums/qasm3_ast.BinaryOp.html +15 -0
  158. package/docs/typedoc/enums/qasm3_ast.DurationUnit.html +7 -0
  159. package/docs/typedoc/enums/qasm3_ast.IOModifier.html +4 -0
  160. package/docs/typedoc/enums/qasm3_ast.MathFunctionTypes.html +12 -0
  161. package/docs/typedoc/enums/qasm3_ast.QuantumGateModifierName.html +6 -0
  162. package/docs/typedoc/enums/qasm3_ast.TrigFunctionTypes.html +8 -0
  163. package/docs/typedoc/enums/qasm3_ast.UnaryOp.html +5 -0
  164. package/docs/typedoc/enums/qasm3_token.Token.html +113 -0
  165. package/docs/typedoc/functions/Lexing.lex.html +24 -0
  166. package/docs/typedoc/functions/Main_Functions.parseFile.html +13 -0
  167. package/docs/typedoc/functions/Main_Functions.parseString.html +19 -0
  168. package/docs/typedoc/functions/Parsing.parse.html +15 -0
  169. package/docs/typedoc/functions/qasm2_token.inverseLookup.html +3 -0
  170. package/docs/typedoc/functions/qasm2_token.lookup.html +4 -0
  171. package/docs/typedoc/functions/qasm2_token.notParam.html +3 -0
  172. package/docs/typedoc/functions/qasm3_token.inverseLookup.html +9 -0
  173. package/docs/typedoc/functions/qasm3_token.lookup.html +10 -0
  174. package/docs/typedoc/functions/qasm3_token.notParam.html +11 -0
  175. package/docs/typedoc/hierarchy.html +1 -0
  176. package/docs/typedoc/index.html +76 -0
  177. package/docs/typedoc/modules/Error_Handling.html +5 -0
  178. package/docs/typedoc/modules/Lexing.html +20 -0
  179. package/docs/typedoc/modules/Main_Functions.html +2 -0
  180. package/docs/typedoc/modules/Parsing.html +24 -0
  181. package/docs/typedoc/modules/Version_Management.html +8 -0
  182. package/docs/typedoc/modules/qasm2_ast.html +22 -0
  183. package/docs/typedoc/modules/qasm2_lexer.html +24 -0
  184. package/docs/typedoc/modules/qasm2_parser.html +21 -0
  185. package/docs/typedoc/modules/qasm2_token.html +15 -0
  186. package/docs/typedoc/modules/qasm3_ast.html +26 -0
  187. package/docs/typedoc/modules/qasm3_lexer.html +25 -0
  188. package/docs/typedoc/modules/qasm3_parser.html +25 -0
  189. package/docs/typedoc/modules/qasm3_token.html +15 -0
  190. package/docs/typedoc/modules.html +1 -0
  191. package/docs/typedoc/types/Error_Handling.ReturnErrorConstructor.html +2 -0
  192. package/docs/typedoc.json +47 -0
  193. package/package.json +6 -2
  194. package/paper/jats/paper.jats +464 -0
  195. package/paper/main.bib +191 -0
  196. package/paper/paper.md +166 -0
  197. package/paper/paper.pdf +0 -0
  198. package/readme.md +73 -10
  199. package/docs/assets/main.js +0 -60
  200. package/docs/assets/navigation.js +0 -1
  201. package/docs/assets/search.js +0 -1
  202. package/docs/assets/style.css +0 -1493
  203. package/docs/classes/errors.BadArgumentError.html +0 -12
  204. package/docs/classes/errors.BadBarrierError.html +0 -12
  205. package/docs/classes/errors.BadClassicalTypeError.html +0 -12
  206. package/docs/classes/errors.BadConditionalError.html +0 -12
  207. package/docs/classes/errors.BadCregError.html +0 -12
  208. package/docs/classes/errors.BadEqualsError.html +0 -12
  209. package/docs/classes/errors.BadExpressionError.html +0 -12
  210. package/docs/classes/errors.BadGateError.html +0 -12
  211. package/docs/classes/errors.BadIncludeError.html +0 -12
  212. package/docs/classes/errors.BadLoopError.html +0 -12
  213. package/docs/classes/errors.BadMeasurementError.html +0 -12
  214. package/docs/classes/errors.BadParameterError.html +0 -12
  215. package/docs/classes/errors.BadQregError.html +0 -12
  216. package/docs/classes/errors.BadQuantumInstructionError.html +0 -12
  217. package/docs/classes/errors.BadStringLiteralError.html +0 -12
  218. package/docs/classes/errors.BadSubroutineError.html +0 -12
  219. package/docs/classes/errors.MissingBraceError.html +0 -12
  220. package/docs/classes/errors.MissingSemicolonError.html +0 -12
  221. package/docs/classes/errors.UnsupportedOpenQASMVersionError.html +0 -12
  222. package/docs/classes/qasm2_ast.ApplyGate.html +0 -6
  223. package/docs/classes/qasm2_ast.AstNode.html +0 -3
  224. package/docs/classes/qasm2_ast.Barrier.html +0 -5
  225. package/docs/classes/qasm2_ast.CReg.html +0 -5
  226. package/docs/classes/qasm2_ast.Cos.html +0 -3
  227. package/docs/classes/qasm2_ast.Divide.html +0 -3
  228. package/docs/classes/qasm2_ast.Exp.html +0 -3
  229. package/docs/classes/qasm2_ast.Gate.html +0 -7
  230. package/docs/classes/qasm2_ast.Id.html +0 -4
  231. package/docs/classes/qasm2_ast.If.html +0 -6
  232. package/docs/classes/qasm2_ast.Include.html +0 -4
  233. package/docs/classes/qasm2_ast.Ln.html +0 -3
  234. package/docs/classes/qasm2_ast.Measure.html +0 -7
  235. package/docs/classes/qasm2_ast.Minus.html +0 -3
  236. package/docs/classes/qasm2_ast.NNInteger.html +0 -4
  237. package/docs/classes/qasm2_ast.Opaque.html +0 -6
  238. package/docs/classes/qasm2_ast.Pi.html +0 -3
  239. package/docs/classes/qasm2_ast.Plus.html +0 -3
  240. package/docs/classes/qasm2_ast.Power.html +0 -3
  241. package/docs/classes/qasm2_ast.QReg.html +0 -5
  242. package/docs/classes/qasm2_ast.Real.html +0 -4
  243. package/docs/classes/qasm2_ast.Sin.html +0 -3
  244. package/docs/classes/qasm2_ast.Sqrt.html +0 -3
  245. package/docs/classes/qasm2_ast.Tan.html +0 -3
  246. package/docs/classes/qasm2_ast.Times.html +0 -3
  247. package/docs/classes/qasm2_ast.Variable.html +0 -4
  248. package/docs/classes/qasm2_ast.Version.html +0 -4
  249. package/docs/classes/qasm2_lexer.default.html +0 -50
  250. package/docs/classes/qasm2_parser.default.html +0 -87
  251. package/docs/classes/qasm3_ast.AliasStatement.html +0 -5
  252. package/docs/classes/qasm3_ast.AngleType.html +0 -4
  253. package/docs/classes/qasm3_ast.Arithmetic.html +0 -6
  254. package/docs/classes/qasm3_ast.ArrayAccess.html +0 -5
  255. package/docs/classes/qasm3_ast.ArrayDeclaration.html +0 -7
  256. package/docs/classes/qasm3_ast.ArrayInitializer.html +0 -4
  257. package/docs/classes/qasm3_ast.ArrayReference.html +0 -5
  258. package/docs/classes/qasm3_ast.AssignmentStatement.html +0 -5
  259. package/docs/classes/qasm3_ast.AstNode.html +0 -3
  260. package/docs/classes/qasm3_ast.Binary.html +0 -6
  261. package/docs/classes/qasm3_ast.BitType.html +0 -4
  262. package/docs/classes/qasm3_ast.BitstringLiteral.html +0 -4
  263. package/docs/classes/qasm3_ast.BoolType.html +0 -3
  264. package/docs/classes/qasm3_ast.BooleanLiteral.html +0 -4
  265. package/docs/classes/qasm3_ast.BoxDefinition.html +0 -7
  266. package/docs/classes/qasm3_ast.BranchingStatement.html +0 -8
  267. package/docs/classes/qasm3_ast.BreakStatement.html +0 -3
  268. package/docs/classes/qasm3_ast.CalibrationGrammarDeclaration.html +0 -6
  269. package/docs/classes/qasm3_ast.CaseStatement.html +0 -5
  270. package/docs/classes/qasm3_ast.Cast.html +0 -5
  271. package/docs/classes/qasm3_ast.ClassicalDeclaration.html +0 -7
  272. package/docs/classes/qasm3_ast.ClassicalType.html +0 -3
  273. package/docs/classes/qasm3_ast.ComplexType.html +0 -6
  274. package/docs/classes/qasm3_ast.ContinueStatement.html +0 -3
  275. package/docs/classes/qasm3_ast.DefaultStatement.html +0 -4
  276. package/docs/classes/qasm3_ast.DurationLiteral.html +0 -5
  277. package/docs/classes/qasm3_ast.DurationOf.html +0 -4
  278. package/docs/classes/qasm3_ast.DurationType.html +0 -3
  279. package/docs/classes/qasm3_ast.Euler.html +0 -3
  280. package/docs/classes/qasm3_ast.Expression.html +0 -3
  281. package/docs/classes/qasm3_ast.ExternSignature.html +0 -8
  282. package/docs/classes/qasm3_ast.FloatLiteral.html +0 -4
  283. package/docs/classes/qasm3_ast.FloatType.html +0 -6
  284. package/docs/classes/qasm3_ast.ForLoopStatement.html +0 -12
  285. package/docs/classes/qasm3_ast.HardwareQubit.html +0 -5
  286. package/docs/classes/qasm3_ast.IODeclaration.html +0 -5
  287. package/docs/classes/qasm3_ast.Identifier.html +0 -4
  288. package/docs/classes/qasm3_ast.ImaginaryLiteral.html +0 -4
  289. package/docs/classes/qasm3_ast.Include.html +0 -6
  290. package/docs/classes/qasm3_ast.IndexSet.html +0 -5
  291. package/docs/classes/qasm3_ast.IntType.html +0 -4
  292. package/docs/classes/qasm3_ast.IntegerLiteral.html +0 -4
  293. package/docs/classes/qasm3_ast.MathFunction.html +0 -5
  294. package/docs/classes/qasm3_ast.NumericLiteral.html +0 -4
  295. package/docs/classes/qasm3_ast.Parameters.html +0 -4
  296. package/docs/classes/qasm3_ast.Pi.html +0 -3
  297. package/docs/classes/qasm3_ast.ProgramBlock.html +0 -7
  298. package/docs/classes/qasm3_ast.QuantumBarrier.html +0 -6
  299. package/docs/classes/qasm3_ast.QuantumBlock.html +0 -6
  300. package/docs/classes/qasm3_ast.QuantumDeclaration.html +0 -8
  301. package/docs/classes/qasm3_ast.QuantumDelay.html +0 -5
  302. package/docs/classes/qasm3_ast.QuantumGateCall.html +0 -9
  303. package/docs/classes/qasm3_ast.QuantumGateDefinition.html +0 -9
  304. package/docs/classes/qasm3_ast.QuantumGateModifier.html +0 -5
  305. package/docs/classes/qasm3_ast.QuantumMeasurement.html +0 -6
  306. package/docs/classes/qasm3_ast.QuantumMeasurementAssignment.html +0 -8
  307. package/docs/classes/qasm3_ast.QuantumReset.html +0 -4
  308. package/docs/classes/qasm3_ast.Range.html +0 -6
  309. package/docs/classes/qasm3_ast.ReturnStatement.html +0 -4
  310. package/docs/classes/qasm3_ast.SizeOf.html +0 -5
  311. package/docs/classes/qasm3_ast.Statement.html +0 -12
  312. package/docs/classes/qasm3_ast.StretchType.html +0 -3
  313. package/docs/classes/qasm3_ast.SubroutineBlock.html +0 -6
  314. package/docs/classes/qasm3_ast.SubroutineCall.html +0 -5
  315. package/docs/classes/qasm3_ast.SubroutineDefinition.html +0 -10
  316. package/docs/classes/qasm3_ast.SubscriptedIdentifier.html +0 -5
  317. package/docs/classes/qasm3_ast.SwitchStatement.html +0 -6
  318. package/docs/classes/qasm3_ast.Tau.html +0 -3
  319. package/docs/classes/qasm3_ast.TrigFunction.html +0 -5
  320. package/docs/classes/qasm3_ast.UIntType.html +0 -4
  321. package/docs/classes/qasm3_ast.Unary.html +0 -5
  322. package/docs/classes/qasm3_ast.Version.html +0 -6
  323. package/docs/classes/qasm3_ast.WhileLoopStatement.html +0 -6
  324. package/docs/classes/qasm3_lexer.default.html +0 -60
  325. package/docs/classes/qasm3_parser.default.html +0 -227
  326. package/docs/classes/version.OpenQASMVersion.html +0 -16
  327. package/docs/enums/qasm2_token.Token.html +0 -39
  328. package/docs/enums/qasm3_ast.ArithmeticOp.html +0 -9
  329. package/docs/enums/qasm3_ast.ArrayReferenceModifier.html +0 -4
  330. package/docs/enums/qasm3_ast.BinaryOp.html +0 -15
  331. package/docs/enums/qasm3_ast.DurationUnit.html +0 -7
  332. package/docs/enums/qasm3_ast.IOModifier.html +0 -4
  333. package/docs/enums/qasm3_ast.MathFunctionTypes.html +0 -12
  334. package/docs/enums/qasm3_ast.QuantumGateModifierName.html +0 -6
  335. package/docs/enums/qasm3_ast.TrigFunctionTypes.html +0 -8
  336. package/docs/enums/qasm3_ast.UnaryOp.html +0 -5
  337. package/docs/enums/qasm3_token.Token.html +0 -101
  338. package/docs/enums/version.OpenQASMMajorVersion.html +0 -4
  339. package/docs/functions/lexer.lex.html +0 -1
  340. package/docs/functions/main.parseFile.html +0 -4
  341. package/docs/functions/main.parseString.html +0 -4
  342. package/docs/functions/parser.parse.html +0 -1
  343. package/docs/functions/qasm2_token.inverseLookup.html +0 -3
  344. package/docs/functions/qasm2_token.lookup.html +0 -4
  345. package/docs/functions/qasm2_token.notParam.html +0 -3
  346. package/docs/functions/qasm3_token.inverseLookup.html +0 -3
  347. package/docs/functions/qasm3_token.lookup.html +0 -4
  348. package/docs/functions/qasm3_token.notParam.html +0 -3
  349. package/docs/hierarchy.html +0 -1
  350. package/docs/modules/errors.html +0 -21
  351. package/docs/modules/lexer.html +0 -2
  352. package/docs/modules/main.html +0 -3
  353. package/docs/modules/parser.html +0 -2
  354. package/docs/modules/qasm2_ast.html +0 -28
  355. package/docs/modules/qasm2_lexer.html +0 -2
  356. package/docs/modules/qasm2_parser.html +0 -2
  357. package/docs/modules/qasm2_token.html +0 -5
  358. package/docs/modules/qasm3_ast.html +0 -83
  359. package/docs/modules/qasm3_lexer.html +0 -2
  360. package/docs/modules/qasm3_parser.html +0 -2
  361. package/docs/modules/qasm3_token.html +0 -5
  362. package/docs/modules/version.html +0 -3
  363. package/docs/modules.html +0 -14
  364. package/docs/types/errors.ReturnErrorConstructor.html +0 -2
  365. /package/docs/{.nojekyll → typedoc/.nojekyll} +0 -0
@@ -0,0 +1,93 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>default | qasm-ts - v2.0.0</title><meta name="description" content="Documentation for qasm-ts"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><link rel="stylesheet" href="../assets/custom.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">qasm-ts - v2.0.0</a><div id="tsd-toolbar-links"><a href="https://github.com/comp-phys-marc/qasm-ts">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts">NPM</a></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="../modules/qasm2_parser.html">qasm2/parser</a></li><li><a href="" aria-current="page">default</a></li></ul><h1>Class default</h1></div><section class="tsd-panel tsd-comment"><div class="tsd-comment tsd-typography"><p>OpenQASM 2.0 Parser</p>
2
+ <p>A straightforward recursive descent parser for OpenQASM 2.0 that produces
3
+ a simplified AST structure appropriate for the more limited feature set
4
+ of the 2.0 language specification.</p>
5
+ </div><div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-basic-parsing-workflow">Example: Basic parsing workflow<a href="#example-basic-parsing-workflow" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-5">const</span><span class="hl-1"> </span><span class="hl-6">parser</span><span class="hl-1"> = </span><span class="hl-5">new</span><span class="hl-1"> </span><span class="hl-0">Parser</span><span class="hl-1">(</span><span class="hl-4">tokens</span><span class="hl-1">);</span><br/><span class="hl-5">const</span><span class="hl-1"> </span><span class="hl-6">ast</span><span class="hl-1"> = </span><span class="hl-4">parser</span><span class="hl-1">.</span><span class="hl-0">parse</span><span class="hl-1">();</span><br/><br/><span class="hl-7">// Process the resulting AST nodes</span><br/><span class="hl-4">ast</span><span class="hl-1">.</span><span class="hl-0">forEach</span><span class="hl-1">(</span><span class="hl-4">node</span><span class="hl-1"> </span><span class="hl-5">=&gt;</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-3">if</span><span class="hl-1"> (</span><span class="hl-4">node</span><span class="hl-1"> </span><span class="hl-5">instanceof</span><span class="hl-1"> </span><span class="hl-9">QReg</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-2">`Quantum register: </span><span class="hl-5">${</span><span class="hl-4">node</span><span class="hl-10">.</span><span class="hl-4">id</span><span class="hl-5">}</span><span class="hl-2">[</span><span class="hl-5">${</span><span class="hl-4">node</span><span class="hl-10">.</span><span class="hl-4">size</span><span class="hl-5">}</span><span class="hl-2">]`</span><span class="hl-1">);</span><br/><span class="hl-1"> }</span><br/><span class="hl-1">});</span>
6
+ </code><button type="button">Copy</button></pre>
7
+
8
+ </div></div></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L96">src/qasm2/parser.ts:96</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
9
+ </div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Methods</h3><div class="tsd-index-list"><a href="#application" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>application</span></a>
10
+ <a href="#barrier" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>barrier</span></a>
11
+ <a href="#conditional" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>conditional</span></a>
12
+ <a href="#creg" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>creg</span></a>
13
+ <a href="#gate" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>gate</span></a>
14
+ <a href="#include" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>include</span></a>
15
+ <a href="#matcharg" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Arg</span></a>
16
+ <a href="#matcharglist" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Arg<wbr/>List</span></a>
17
+ <a href="#matchidlist" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Id<wbr/>List</span></a>
18
+ <a href="#matchnext" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Next</span></a>
19
+ <a href="#matchparam" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Param</span></a>
20
+ <a href="#matchparamlist" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Param<wbr/>List</span></a>
21
+ <a href="#measure" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>measure</span></a>
22
+ <a href="#opaque" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>opaque</span></a>
23
+ <a href="#parse" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>parse</span></a>
24
+ <a href="#parsenode" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>parse<wbr/>Node</span></a>
25
+ <a href="#qreg" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>qreg</span></a>
26
+ <a href="#sub" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>sub</span></a>
27
+ <a href="#versionheader" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>version<wbr/>Header</span></a>
28
+ </div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="#gates" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>gates</span></a>
29
+ <a href="#tokens" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>tokens</span></a>
30
+ </div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructordefault"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">default</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">default</a><a href="#constructordefault" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a parser.</p>
31
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
32
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">default</a></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L107">src/qasm2/parser.ts:107</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Methods</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="application"><span>application</span><a href="#application" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="application-1"><span class="tsd-kind-call-signature">application</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">op</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span><a href="#application-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses an application of one of the allowed gates.</p>
33
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
34
+ </div></li><li><span><span class="tsd-kind-parameter">op</span>: <span class="tsd-signature-type">string</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span></h4><p>An AST node representing the gate application.</p>
35
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L421">src/qasm2/parser.ts:421</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="barrier"><span>barrier</span><a href="#barrier" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="barrier-1"><span class="tsd-kind-call-signature">barrier</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#barrier-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a barrier.</p>
36
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
37
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the barrier.</p>
38
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L339">src/qasm2/parser.ts:339</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="conditional"><span>conditional</span><a href="#conditional" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="conditional-1"><span class="tsd-kind-call-signature">conditional</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#conditional-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a conditional.</p>
39
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
40
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the conditional.</p>
41
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L315">src/qasm2/parser.ts:315</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="creg"><span>creg</span><a href="#creg" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="creg-1"><span class="tsd-kind-call-signature">creg</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#creg-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a classical register.</p>
42
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
43
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the classical register.</p>
44
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L289">src/qasm2/parser.ts:289</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="gate"><span>gate</span><a href="#gate" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="gate-1"><span class="tsd-kind-call-signature">gate</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#gate-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a gate.</p>
45
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
46
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the gate.</p>
47
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L660">src/qasm2/parser.ts:660</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="include"><span>include</span><a href="#include" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="include-1"><span class="tsd-kind-call-signature">include</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.Include.html" class="tsd-signature-type tsd-kind-class">Include</a><a href="#include-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses an include statement.</p>
48
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
49
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.Include.html" class="tsd-signature-type tsd-kind-class">Include</a></h4><p>An Include node representing the include statement.</p>
50
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L598">src/qasm2/parser.ts:598</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="matcharg"><span>match<wbr/>Arg</span><a href="#matcharg" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="matcharg-1"><span class="tsd-kind-call-signature">matchArg</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><a href="#matcharg-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses an argument value.</p>
51
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
52
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4><p>An AST node representing the argument value.</p>
53
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L539">src/qasm2/parser.ts:539</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="matcharglist"><span>match<wbr/>Arg<wbr/>List</span><a href="#matcharglist" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="matcharglist-1"><span class="tsd-kind-call-signature">matchArgList</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><a href="#matcharglist-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a list of argument values.</p>
54
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
55
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></h4><p>An array of AST nodes representing the argument values.</p>
56
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L562">src/qasm2/parser.ts:562</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="matchidlist"><span>match<wbr/>Id<wbr/>List</span><a href="#matchidlist" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="matchidlist-1"><span class="tsd-kind-call-signature">matchIdList</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><a href="#matchidlist-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a list of identifiers.</p>
57
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
58
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></h4><p>An array of AST nodes representing the identifiers.</p>
59
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L639">src/qasm2/parser.ts:639</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="matchnext"><span>match<wbr/>Next</span><a href="#matchnext" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="matchnext-1"><span class="tsd-kind-call-signature">matchNext</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">expectedTokens</span><span class="tsd-signature-symbol">:</span> <a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#matchnext-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Checks if the next tokens match those expected.</p>
60
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
61
+ </div></li><li><span><span class="tsd-kind-parameter">expectedTokens</span>: <a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Expected tokens.</p>
62
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><p>Whether these is a match.</p>
63
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L239">src/qasm2/parser.ts:239</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="matchparam"><span>match<wbr/>Param</span><a href="#matchparam" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="matchparam-1"><span class="tsd-kind-call-signature">matchParam</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#matchparam-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a parameter value.</p>
64
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
65
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the parameter value.</p>
66
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L490">src/qasm2/parser.ts:490</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="matchparamlist"><span>match<wbr/>Param<wbr/>List</span><a href="#matchparamlist" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="matchparamlist-1"><span class="tsd-kind-call-signature">matchParamList</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><a href="#matchparamlist-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a list of parameter values.</p>
67
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
68
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>An array of AST nodes representing the parameter values.</p>
69
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L505">src/qasm2/parser.ts:505</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="measure"><span>measure</span><a href="#measure" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="measure-1"><span class="tsd-kind-call-signature">measure</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#measure-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a measurement.</p>
70
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
71
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the measurement.</p>
72
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L365">src/qasm2/parser.ts:365</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="opaque"><span>opaque</span><a href="#opaque" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="opaque-1"><span class="tsd-kind-call-signature">opaque</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#opaque-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses an opaque declaration if using OpenQASM 2. If using OpenQASM 3 it skips the line.</p>
73
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
74
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the opaque declaration.</p>
75
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L696">src/qasm2/parser.ts:696</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="parse"><span>parse</span><a href="#parse" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="parse-1"><span class="tsd-kind-call-signature">parse</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span><a href="#parse-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Calling this method parses the code represented by the provided tokens.</p>
76
+ </div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span></h4><p>The abstract syntax tree.</p>
77
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L136">src/qasm2/parser.ts:136</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="parsenode"><span>parse<wbr/>Node</span><a href="#parsenode" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="parsenode-1"><span class="tsd-kind-call-signature">parseNode</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">allowVariables</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span><a href="#parsenode-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Delegates the parsing of the next set of tokens to the appropriate method.</p>
78
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
79
+ </div></li><li><span><span class="tsd-kind-parameter">allowVariables</span>: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></span><div class="tsd-comment tsd-typography"><p>Whether encountered identifiers should be consider
80
+ variable initializations or references.</p>
81
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span></h4><p>A set of AST nodes.</p>
82
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L163">src/qasm2/parser.ts:163</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="qreg"><span>qreg</span><a href="#qreg" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="qreg-1"><span class="tsd-kind-call-signature">qreg</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><a href="#qreg-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a quantum register.</p>
83
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Remaining tokens to parse.</p>
84
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a></h4><p>An AST node representing the quantum register.</p>
85
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L263">src/qasm2/parser.ts:263</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="sub"><span>sub</span><a href="#sub" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="sub-1"><span class="tsd-kind-call-signature">sub</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span><a href="#sub-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses a subroutine used in a custom gate definition.</p>
86
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Expression tokens to parse.</p>
87
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><span class="tsd-signature-symbol">[]</span></h4><p>A parsed subroutine.</p>
88
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L462">src/qasm2/parser.ts:462</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="versionheader"><span>version<wbr/>Header</span><a href="#versionheader" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="versionheader-1"><span class="tsd-kind-call-signature">versionHeader</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="qasm2_ast.Version.html" class="tsd-signature-type tsd-kind-class">Version</a><a href="#versionheader-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Parses the version header and sets the parser version.</p>
89
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tokens</span>: <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Tokens to parse.</p>
90
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="qasm2_ast.Version.html" class="tsd-signature-type tsd-kind-class">Version</a></h4><p>A Version node representing the version statement.</p>
91
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L612">src/qasm2/parser.ts:612</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Properties</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="gates"><span>gates</span><a href="#gates" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">gates</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></div><div class="tsd-comment tsd-typography"><p>The allowed gates.</p>
92
+ </div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L101">src/qasm2/parser.ts:101</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="tokens"><span>tokens</span><a href="#tokens" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">tokens</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><a href="../enums/qasm2_token.Token.html" class="tsd-signature-type tsd-kind-enum">Token</a><span class="tsd-signature-symbol">,</span> (<span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">number</span>)<span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></div><div class="tsd-comment tsd-typography"><p>The tokens to parse.</p>
93
+ </div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm2/parser.ts#L98">src/qasm2/parser.ts:98</a></li></ul></aside></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Methods</summary><div><a href="#application"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>application</span></a><a href="#barrier"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>barrier</span></a><a href="#conditional"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>conditional</span></a><a href="#creg"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>creg</span></a><a href="#gate"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>gate</span></a><a href="#include"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>include</span></a><a href="#matcharg"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Arg</span></a><a href="#matcharglist"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Arg<wbr/>List</span></a><a href="#matchidlist"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Id<wbr/>List</span></a><a href="#matchnext"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Next</span></a><a href="#matchparam"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Param</span></a><a href="#matchparamlist"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>match<wbr/>Param<wbr/>List</span></a><a href="#measure"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>measure</span></a><a href="#opaque"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>opaque</span></a><a href="#parse"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>parse</span></a><a href="#parsenode"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>parse<wbr/>Node</span></a><a href="#qreg"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>qreg</span></a><a href="#sub"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>sub</span></a><a href="#versionheader"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>version<wbr/>Header</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#gates"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>gates</span></a><a href="#tokens"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>tokens</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://github.com/comp-phys-marc/qasm-ts" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts" class="tsd-nav-link">NPM</a></nav><nav class="tsd-navigation"><a href="../modules.html">qasm-ts - v2.0.0</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer></footer><div class="overlay"></div></body></html>
@@ -0,0 +1,5 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>AliasStatement | qasm-ts - v2.0.0</title><meta name="description" content="Documentation for qasm-ts"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><link rel="stylesheet" href="../assets/custom.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">qasm-ts - v2.0.0</a><div id="tsd-toolbar-links"><a href="https://github.com/comp-phys-marc/qasm-ts">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts">NPM</a></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="../modules/qasm3_ast.html">qasm3/ast</a></li><li><a href="" aria-current="page">AliasStatement</a></li></ul><h1>Class AliasStatement</h1></div><section class="tsd-panel tsd-comment"><div class="tsd-comment tsd-typography"><p>Class representing an alias statement.</p>
2
+ </div></section><section class="tsd-panel tsd-hierarchy" data-refl="888"><h4>Hierarchy (<a href="../hierarchy.html#qasm3/ast.AliasStatement">View Summary</a>)</h4><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><a href="qasm3_ast.AstNode.html" class="tsd-signature-type tsd-kind-class">AstNode</a><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><span class="tsd-hierarchy-target">AliasStatement</span></li></ul></li></ul></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L652">src/qasm3/ast.ts:652</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
3
+ </div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="#identifier" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>identifier</span></a>
4
+ <a href="#value" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>value</span></a>
5
+ </div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructoraliasstatement"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">AliasStatement</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">identifier</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Identifier.html" class="tsd-signature-type tsd-kind-class">Identifier</a><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">value</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">AliasStatement</a><a href="#constructoraliasstatement" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">identifier</span>: <a href="qasm3_ast.Identifier.html" class="tsd-signature-type tsd-kind-class">Identifier</a></span></li><li><span><span class="tsd-kind-parameter">value</span>: <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">AliasStatement</a></h4><aside class="tsd-sources"><p>Overrides <a href="qasm3_ast.AstNode.html">AstNode</a>.<a href="qasm3_ast.AstNode.html#constructor">constructor</a></p><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L655">src/qasm3/ast.ts:655</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Properties</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="identifier"><span>identifier</span><a href="#identifier" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">identifier</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Identifier.html" class="tsd-signature-type tsd-kind-class">Identifier</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L653">src/qasm3/ast.ts:653</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="value"><span>value</span><a href="#value" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">value</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L654">src/qasm3/ast.ts:654</a></li></ul></aside></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#identifier"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>identifier</span></a><a href="#value"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>value</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://github.com/comp-phys-marc/qasm-ts" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts" class="tsd-nav-link">NPM</a></nav><nav class="tsd-navigation"><a href="../modules.html">qasm-ts - v2.0.0</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer></footer><div class="overlay"></div></body></html>
@@ -0,0 +1,4 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>AngleType | qasm-ts - v2.0.0</title><meta name="description" content="Documentation for qasm-ts"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><link rel="stylesheet" href="../assets/custom.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">qasm-ts - v2.0.0</a><div id="tsd-toolbar-links"><a href="https://github.com/comp-phys-marc/qasm-ts">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts">NPM</a></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="../modules/qasm3_ast.html">qasm3/ast</a></li><li><a href="" aria-current="page">AngleType</a></li></ul><h1>Class AngleType</h1></div><section class="tsd-panel tsd-comment"><div class="tsd-comment tsd-typography"><p>Class representing an angle type.</p>
2
+ </div></section><section class="tsd-panel tsd-hierarchy" data-refl="632"><h4>Hierarchy (<a href="../hierarchy.html#qasm3/ast.AngleType">View Summary</a>)</h4><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><a href="qasm3_ast.ClassicalType.html" class="tsd-signature-type tsd-kind-class">ClassicalType</a><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><span class="tsd-hierarchy-target">AngleType</span></li></ul></li></ul></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L185">src/qasm3/ast.ts:185</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
3
+ </div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="#size" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>size</span></a>
4
+ </div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructorangletype"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">AngleType</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">size</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">|</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">AngleType</a><a href="#constructorangletype" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">size</span>: <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">|</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">AngleType</a></h4><aside class="tsd-sources"><p>Overrides <a href="qasm3_ast.ClassicalType.html">ClassicalType</a>.<a href="qasm3_ast.ClassicalType.html#constructor">constructor</a></p><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L187">src/qasm3/ast.ts:187</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Properties</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="size"><span>size</span><a href="#size" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">size</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">|</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L186">src/qasm3/ast.ts:186</a></li></ul></aside></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#size"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>size</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://github.com/comp-phys-marc/qasm-ts" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts" class="tsd-nav-link">NPM</a></nav><nav class="tsd-navigation"><a href="../modules.html">qasm-ts - v2.0.0</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer></footer><div class="overlay"></div></body></html>
@@ -0,0 +1,6 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>Arithmetic | qasm-ts - v2.0.0</title><meta name="description" content="Documentation for qasm-ts"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><link rel="stylesheet" href="../assets/custom.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">qasm-ts - v2.0.0</a><div id="tsd-toolbar-links"><a href="https://github.com/comp-phys-marc/qasm-ts">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts">NPM</a></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="../modules/qasm3_ast.html">qasm3/ast</a></li><li><a href="" aria-current="page">Arithmetic</a></li></ul><h1>Class Arithmetic</h1></div><section class="tsd-panel tsd-comment"><div class="tsd-comment tsd-typography"><p>Class representing an arithmetic operator expression.</p>
2
+ </div></section><section class="tsd-panel tsd-hierarchy" data-refl="779"><h4>Hierarchy (<a href="../hierarchy.html#qasm3/ast.Arithmetic">View Summary</a>)</h4><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><span class="tsd-hierarchy-target">Arithmetic</span></li></ul></li></ul></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L427">src/qasm3/ast.ts:427</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
3
+ </div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="#left" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>left</span></a>
4
+ <a href="#op" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>op</span></a>
5
+ <a href="#right" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>right</span></a>
6
+ </div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructorarithmetic"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">Arithmetic</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">op</span><span class="tsd-signature-symbol">:</span> <a href="../enums/qasm3_ast.ArithmeticOp.html" class="tsd-signature-type tsd-kind-enum">ArithmeticOp</a><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">left</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">right</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">Arithmetic</a><a href="#constructorarithmetic" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">op</span>: <a href="../enums/qasm3_ast.ArithmeticOp.html" class="tsd-signature-type tsd-kind-enum">ArithmeticOp</a></span></li><li><span><span class="tsd-kind-parameter">left</span>: <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></span></li><li><span><span class="tsd-kind-parameter">right</span>: <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">Arithmetic</a></h4><aside class="tsd-sources"><p>Overrides <a href="qasm3_ast.Expression.html">Expression</a>.<a href="qasm3_ast.Expression.html#constructor">constructor</a></p><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L431">src/qasm3/ast.ts:431</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Properties</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="left"><span>left</span><a href="#left" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">left</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L429">src/qasm3/ast.ts:429</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="op"><span>op</span><a href="#op" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">op</span><span class="tsd-signature-symbol">:</span> <a href="../enums/qasm3_ast.ArithmeticOp.html" class="tsd-signature-type tsd-kind-enum">ArithmeticOp</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L428">src/qasm3/ast.ts:428</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="right"><span>right</span><a href="#right" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">right</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L430">src/qasm3/ast.ts:430</a></li></ul></aside></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#left"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>left</span></a><a href="#op"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>op</span></a><a href="#right"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>right</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://github.com/comp-phys-marc/qasm-ts" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts" class="tsd-nav-link">NPM</a></nav><nav class="tsd-navigation"><a href="../modules.html">qasm-ts - v2.0.0</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer></footer><div class="overlay"></div></body></html>
@@ -0,0 +1,5 @@
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>ArrayAccess | qasm-ts - v2.0.0</title><meta name="description" content="Documentation for qasm-ts"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><link rel="stylesheet" href="../assets/custom.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">qasm-ts - v2.0.0</a><div id="tsd-toolbar-links"><a href="https://github.com/comp-phys-marc/qasm-ts">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts">NPM</a></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="../modules/qasm3_ast.html">qasm3/ast</a></li><li><a href="" aria-current="page">ArrayAccess</a></li></ul><h1>Class ArrayAccess</h1></div><section class="tsd-panel tsd-comment"><div class="tsd-comment tsd-typography"><p>Class representing an array access</p>
2
+ </div></section><section class="tsd-panel tsd-hierarchy" data-refl="839"><h4>Hierarchy (<a href="../hierarchy.html#qasm3/ast.ArrayAccess">View Summary</a>)</h4><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><ul class="tsd-hierarchy"><li class="tsd-hierarchy-item"><span class="tsd-hierarchy-target">ArrayAccess</span></li></ul></li></ul></section><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L541">src/qasm3/ast.ts:541</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
3
+ </div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Properties</h3><div class="tsd-index-list"><a href="#array" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>array</span></a>
4
+ <a href="#indices" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>indices</span></a>
5
+ </div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Constructors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="constructor"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="constructorarrayaccess"><span class="tsd-signature-keyword">new</span> <span class="tsd-kind-constructor-signature">ArrayAccess</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">array</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Identifier.html" class="tsd-signature-type tsd-kind-class">Identifier</a><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">indices</span><span class="tsd-signature-symbol">?:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">|</span> <a href="qasm3_ast.Range.html" class="tsd-signature-type tsd-kind-class">Range</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="" class="tsd-signature-type tsd-kind-class">ArrayAccess</a><a href="#constructorarrayaccess" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">array</span>: <a href="qasm3_ast.Identifier.html" class="tsd-signature-type tsd-kind-class">Identifier</a></span></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">indices</span>: <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">|</span> <a href="qasm3_ast.Range.html" class="tsd-signature-type tsd-kind-class">Range</a></span></li></ul></div><h4 class="tsd-returns-title">Returns <a href="" class="tsd-signature-type tsd-kind-class">ArrayAccess</a></h4><aside class="tsd-sources"><p>Overrides <a href="qasm3_ast.Expression.html">Expression</a>.<a href="qasm3_ast.Expression.html#constructor">constructor</a></p><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L544">src/qasm3/ast.ts:544</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Properties</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="array"><span>array</span><a href="#array" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">array</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Identifier.html" class="tsd-signature-type tsd-kind-class">Identifier</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L542">src/qasm3/ast.ts:542</a></li></ul></aside></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="indices"><span>indices</span><a href="#indices" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><div class="tsd-signature"><span class="tsd-kind-property">indices</span><span class="tsd-signature-symbol">:</span> <a href="qasm3_ast.Expression.html" class="tsd-signature-type tsd-kind-class">Expression</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">|</span> <a href="qasm3_ast.Range.html" class="tsd-signature-type tsd-kind-class">Range</a></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/comp-phys-marc/qasm-ts/blob/e00e770e8986980469d62d6791dabda601cde7ad/src/qasm3/ast.ts#L543">src/qasm3/ast.ts:543</a></li></ul></aside></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Constructor"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Properties"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Properties</summary><div><a href="#array"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>array</span></a><a href="#indices"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Property"><use href="../assets/icons.svg#icon-1024"></use></svg><span>indices</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://github.com/comp-phys-marc/qasm-ts" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/qasm-ts" class="tsd-nav-link">NPM</a></nav><nav class="tsd-navigation"><a href="../modules.html">qasm-ts - v2.0.0</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer></footer><div class="overlay"></div></body></html>