block:
# works
const Foo {.deprecated.} = 1
block:
# Error: annotation to deprecated not supported here
# const Foo {.deprecated: "bla".} = 1
{.deprecated: "blabla".} goes before the = but not for object type:block:
# object type: deprecated goes after `=`
type Foo = object {.deprecated: "blabla".}
a: int
block:
# every thing else: deprecated goes before `=`: enum, routines, const/let/var
type Foo {.deprecated: "asdf" .} = enum
a
This could have been separated to two issues, each with a small, not an essay title:
Seriously, you should start minimizing your issue title to not scare people away, avoiding symbols might be a good start. Just my 2垄.
Seriously, you should start minimizing your issue title to not scare people away, avoiding symbols might be a good start. Just my 2垄.
I understand your points and will keep in mind; there's a tradeoff between precision and conciseness; regarding symbols, {.deprecated: "msg" .} may make it easier to search (via {.deprecated: ") compared to deprecated pragma with annotation (lots of synonyms in english) when searching with in:title but YMMV
likewise with grouping vs splitting related issues; in some similar past cases others were recommending grouping instead; so it's not completely obvious.
Part 2 fixed by - https://github.com/nim-lang/Nim/commit/05b8085a873ad0d8e5e823d35a0b043997e873df
Part 1 - PR https://github.com/nim-lang/Nim/pull/10110 These symbols do not store enough information currently so the patch does not work (more information). Patch added for vars/lets https://github.com/nim-lang/Nim/pull/10234
Only remaining issue is const
Most helpful comment
This could have been separated to two issues, each with a small, not an essay title:
Seriously, you should start minimizing your issue title to not scare people away, avoiding symbols might be a good start. Just my 2垄.