Skip to content

Private methods of a an exported object are publicly exported #18

@SamuraiCrow

Description

@SamuraiCrow
EXPORT OBJECT arf PRIVATE
  bla
ENDOBJECT

EXPORT PROC dog() OF arf IS WriteF('I should be exported.')

PROC cat() OF arf IS WriteF('I should not be exported.')

Using viewmodule reveals that the cat() method is also exported.

As a workaround, make cat a local function and pass in self as a PTR TO arf so it is not a method of arf directly.

PROC cat(self:PTR TO arf) IS WriteF('I am not exported now.')

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions