Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Message formatting when using @nowarn("verbose") #22412

Closed
lrytz opened this issue Jan 20, 2025 · 0 comments · Fixed by #22434
Closed

Message formatting when using @nowarn("verbose") #22412

lrytz opened this issue Jan 20, 2025 · 0 comments · Fixed by #22434
Labels
area:reporting Error reporting including formatting, implicit suggestions, etc good first issue Perfect for someone who wants to get started contributing itype:bug

Comments

@lrytz
Copy link
Member

lrytz commented Jan 20, 2025

class C:
  @annotation.nowarn("v") def f = try 1

shows

-- [E002] Syntax Warning: /Users/luc/code/scala/scala13/sandbox/A.scala:2:34 ---
2 |  @annotation.nowarn("v") def f = try 1
  |                                  ^^^^^
  |                   A try without catch or finally is equivalent to putting
  |                   its body in a block; no exceptions are handled.
Matching filters for @nowarn or -Wconf:
  - id=E2
  - name=EmptyCatchAndFinallyBlock
  |
  | longer explanation available when compiling with `-explain`

The | margin is missing.

@lrytz lrytz added area:reporting Error reporting including formatting, implicit suggestions, etc good first issue Perfect for someone who wants to get started contributing itype:bug stat:needs triage Every issue needs to have an "area" and "itype" label labels Jan 20, 2025
@Gedochao Gedochao removed the stat:needs triage Every issue needs to have an "area" and "itype" label label Jan 20, 2025
@lrytz lrytz closed this as completed in 0e567c1 Jan 23, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
area:reporting Error reporting including formatting, implicit suggestions, etc good first issue Perfect for someone who wants to get started contributing itype:bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants