Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

XS0102 error: The type 'XXXX' already contains a definition for 'YYYY' 09 Jan 2022 20:44 #21058

  • alex_schmitt


  • Posts: 10
  • Hi all,

    after using VoXPorter I get tons of errors "XS0102: The type 'XXXX' already contains a definition for 'YYYY'"

    Interestingly enough, I did not find any resolution in the documents nor in the forum.

    I have a lot of PROTECT variables in my classes that I access and assign as follows:
    CLASS A
    PROTECT VarA
    
    ACCESS VarA
    return self:VarA
    
    Assign VarA(value)
    self:VarA:=value
    

    Of course I can refactor and create getters and setters as follows:
    ACCESS getVarA
    return self:VarA
    
    Assign setVarA(value)
    self:VarA:=value

    But before I do that I wanted to double check that this is the only option as this is pretty error-prone and exhausting when I am doing that in VO.

    Any thoughts would be helpful :)

    Best,
    Alex

    Please Log in or Create an account to join the conversation.

    XS0102 error: The type 'XXXX' already contains a definition for 'YYYY' 09 Jan 2022 20:49 #21059

    • robert
    • robert's Avatar


  • Posts: 2593
  • Alex,
    From which version of VO are you coming.
    VO 2.8 should have already warned you for that.
    There is an option in the VOXPorter to detect this. This option will prefix the protected variable with an underscore IIRC.

    Robert
    XSharp Development Team
    The Netherlands

    Please Log in or Create an account to join the conversation.

    XS0102 error: The type 'XXXX' already contains a definition for 'YYYY' 09 Jan 2022 21:23 #21060

    • alex_schmitt


  • Posts: 10
  • Hi Robert,

    wow the speed you guys are responding is truely amazing.

    Yes, the "CheckForIVarAndPropertyConflicts" flag did the trick! I am using 2.8 SP4 Build 2838. I assume there was a warning but I did not take it serious.

    Best,
    Alex

    Please Log in or Create an account to join the conversation.

    • Page:
    • 1