Diagnostic and cause
СсылкаSemicolon in delimiter list
- Семейство
- topaz
- Этап
- layout
- Код
TPZ1001
Причина и условия
List elements use commas. A semicolon in a delimiter list produces TPZ1001 at the semicolon.
Связанное правило · Trigger and repair →Действия
Use a comma between list elements. Put independent statements in a block that accepts statements.
Compiler phase: layout.
Compiler explanation: A semicolon appeared where a comma/newline-separated delimiter list is required.
Message templates. The marker ⟨value⟩ stands for text computed for the reported program.
;does not separate items inside a delimiter list; use,Source
Observed for the candidate in Topaz 5.21.3. Execution
- error[TPZ1001]:
;does not separate items inside a delimiter list; use,
A semicolon occurs inside a list whose elements require a list separator. Statement separation does not make it an element separator.
Trigger and repair
List elements use commas. A semicolon in a delimiter list produces TPZ1001 at the semicolon.
Response
СсылкаUse a comma between list elements. Put independent statements in a block that accepts statements.
Reproduction and verification
СсылкаRejected program
Ссылкаlet values = [1; 2]
Нет стандартного вывода.Ожидаемый результат
Ожидаемый результат
Этап отклонения layout. Ненулевой код завершения.
diagnostic-tpz1001 at
example.tpz:1:16
The expected diagnostic, cause, source location, and accompanying diagnostics are specified below. The verification status records whether this program has been run.
Corrected program
Ссылкаlet values = [1, 2]
Ожидаемый результат
Ожидаемый результат
Проверка принимает программу. Код завершения 0.
This program applies the repair described above. The verification status records whether it has been run.