<div dir="ltr">Hi all,<div><br></div><div>I am currently migrating a Haskell project that uses ghc 8.10.7 to ghc 9.6.4. </div><div><br></div><div>Using the new version, I get errors like</div><div><br></div><div>~~~.haskell</div><div>Ambiguous occurrence ‘pos’<br>It could refer to<br>   either the field ‘pos’ of record ‘PClassify’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:1265:5<br>       or the field ‘pos’ of record ‘PPurpose’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:1186:5<br>       or the field ‘pos’ of record ‘P_ViewSegment’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:1129:5<br>       or the field ‘pos’ of record ‘P_ViewD’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:1080:5<br>       or the field ‘pos’ of record ‘P_IdentDf’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:1024:5<br>       or the field ‘pos’ of record ‘P_BoxItem’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:981:9<br>       or the field ‘pos’ of record ‘TemplateKeyValue’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:959:5<br>       or the field ‘pos’ of record ‘BoxHeader’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:947:5<br>       or the field ‘pos’ of record ‘P_SubIfc’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:934:9<br>       or the field ‘pos’ of record ‘P_Interface’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:899:5<br>       or the field ‘pos’ of record ‘P_Population’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:870:9<br>       or the field ‘pos’ of record ‘P_Rule’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:806:5<br>       or the field ‘pos’ of record ‘PairViewSegment’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:740:9<br>       or the field ‘pos’ of record ‘P_NamedRel’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:591:5<br>       or the field ‘pos’ of record ‘PAtomPair’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:467:5<br>       or the field ‘pos’ of record ‘Pragma’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:415:5<br>       or the field ‘pos’ of record ‘P_Relation’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:408:5<br>       or the field ‘pos’ of record ‘Representation’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:339:5<br>       or the field ‘pos’ of record ‘PConceptDef’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:268:5<br>       or the field ‘pos’ of record ‘P_Pattern’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:209:5<br>       or the field ‘pos’ of record ‘Role’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:185:5<br>       or the field ‘pos’ of record ‘P_RoleRule’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:172:5<br>       or the field ‘pos’ of record ‘P_Enforce’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:152:5<br>       or the field ‘pos’ of record ‘MetaData’,<br>          defined at /workspaces/AmpersandNamespace/src/Ampersand/Core/ParseTree.hs:136:5<br></div><div><br></div><div>Previously, it was totally fine to have different data types each have a field with the same name, as long as you used `<span style="color:rgb(86,156,214);background-color:rgb(30,30,30);font-family:Consolas,"Courier New",monospace;font-size:14px;white-space:pre">DuplicateRecordFields</span>`</div><div><br></div><div>I have searched the migration documentation but I couldn't find any clue on why this has been changed or how to deal with it. I probably missed it. </div><div>Any help is mostly appreciated!</div><div><br></div><div>Thanks for reading</div><div>Cheers,</div><div>Han Joosten</div><div><br></div><div><br></div></div>