dfinity / motoko

Simple high-level language for writing Internet Computer canisters
Apache License 2.0
493 stars 97 forks source link

Bug when mo-doc generating docs for public var. #4579

Open AStepanov25 opened 1 week ago

AStepanov25 commented 1 week ago

This code:

module {
  public class Class() {
    /// Docs
    public var a : Nat = 0;
  };
};

when being run with this command:

$(dfx cache show)/mo-doc --format plain

causes this output:

Failed to extract documentation for declaration:
(VarD a (AnnotE (LitE (PreLit 0 Nat)) (PathT (IdH Nat))))

and no doc for public variable in md file.

rvanasa commented 6 days ago

Thank you for the bug report! We are tracking this issue internally and will look into fixing this when possible.