Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0006387OCamlOCaml generalpublic2014-04-30 05:372014-05-05 13:28
Reporterwhitequark 
Assigned Tofrisch 
PrioritynormalSeverityfeatureReproducibilityhave not tried
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version4.02.0+dev 
Summary0006387: Parsetree.row_field.Rtag should contain attributes
DescriptionI am developing an extension for serializing data to Protocol Buffers. In particular, it accepts attributes on variant constructors that define their mapping to integer keys used in the protocol, like this: `type v = A [@key 1] | B [@key 10] of int`.

It would make sense if I could define the exact same type, mapping to exact same message, with polymorphic variants: `type v' = `A [@key 1] | `B [@key 10] of int'. However, this is currently not possible, as parser does not accept attributes in that position.
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0011337)
frisch (developer)
2014-04-30 10:24

Wish granted by commit 14712 on trunk. ppx_tools has been adapted.

(The internal representation of Rtag might change in the future.)
(0011349)
frisch (developer)
2014-05-05 13:22

By symmetry, attributes are now also allowed on methods in object types:

 type t = < m [@foo] : int >
(0011350)
frisch (developer)
2014-05-05 13:28

Manual and ppx_tools have been adapted.

- Issue History
Date Modified Username Field Change
2014-04-30 05:37 whitequark New Issue
2014-04-30 10:16 frisch Assigned To => frisch
2014-04-30 10:16 frisch Status new => assigned
2014-04-30 10:24 frisch Note Added: 0011337
2014-04-30 10:25 frisch Fixed in Version => 4.02.0+dev
2014-05-05 13:22 frisch Note Added: 0011349
2014-05-05 13:28 frisch Note Added: 0011350
2014-05-05 13:28 frisch Status assigned => resolved
2014-05-05 13:28 frisch Resolution open => fixed


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker