Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

pprintast ignores attributes in tails of a list #7506

Closed
vicuna opened this Issue Mar 20, 2017 · 5 comments

Comments

Projects
None yet
2 participants
@vicuna
Copy link
Collaborator

vicuna commented Mar 20, 2017

Original bug ID: 7506
Reporter: @kenichi-asai
Assigned to: @alainfrisch
Status: resolved (set by @alainfrisch on 2017-04-10T16:38:12Z)
Resolution: fixed
Priority: low
Severity: minor
Platform: Apple
OS: MacOS X
OS Version: 10.12
Version: 4.04.0
Fixed in version: 4.06.0 +dev/beta1/beta2/rc1
Category: lexing and parsing

Bug description

Let a.ml be:

let a = ([1; 2])[@hello]
let b = 0::(([1; 2])[@hello])

$ ocamlc -dsource a.ml
let a = (([1; 2])[@hello ])
let b = [0; 1; 2]

where the attribute for [1; 2] in b is ignored. The output for b should be 0::(([1; 2])[@hello ]).

@vicuna

This comment has been minimized.

Copy link
Collaborator Author

vicuna commented Mar 20, 2017

Comment author: @gasche

I could reproduce under the 4.05 branch and trunk.

@vicuna

This comment has been minimized.

Copy link
Collaborator Author

vicuna commented Apr 10, 2017

Comment author: @alainfrisch

Fixed by commit 73227ba on trunk.

@vicuna

This comment has been minimized.

Copy link
Collaborator Author

vicuna commented Apr 10, 2017

Comment author: @gasche

I found 6 more instances of the bug pattern, pointed out in the comments in

73227ba

@vicuna

This comment has been minimized.

Copy link
Collaborator Author

vicuna commented Apr 10, 2017

Comment author: @alainfrisch

Thanks Gabriel. Reopening.

@vicuna

This comment has been minimized.

Copy link
Collaborator Author

vicuna commented Apr 10, 2017

Comment author: @alainfrisch

d26c298 fixes those other similar cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.