-
Notifications
You must be signed in to change notification settings - Fork 136
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
Issues with type bound procedures: incomplete source code and 404 #450
Comments
|
I think that would be ill-advised. If the implementation is private and you don't want to see private things then it should not have a dedicated page of documentation for it. Only the interface should be documented, in the type-binding. However, FORD should also be designed not to generate a broken link in that case (I'm surprised that wasn't already the case!). |
True, but type-bound procedures are a bit weird like that -- if the type is public then so are its procedures (unless made explicitly private), but the un-bound names may still be private. I don't think they are implementation details in that case, it's just forbidding one name ( I'm sure how FORD should indicate that, but I think the simple fix of "public type-bound procedures are public procedures" is the most expedient, at least for the time being. |
It's only the procedure bindings which will be public in that case; not the procedures themselves. The documentation being discussed here is for the bindings only, not for the actual procedures. FORD is designed to maintain that distinction. If we were to take the approach that the implementations of public type-bound procedures should automatically be treated as public then we would have to apply that to overloads in public generic interfaces as well (which are currently treated the same way as type-bound procedures). I think that it is useful to maintain the current behaviour as it reinforces the fact that type-bindings of procedures are distinct from the actual procedures themselves. Unlike in C++, for example, these procedures have not automatic access to variables of the derived type. They exist totally separately from the derived type and should therefore have their own visibility logic. If we were to go down the route you propose, I would at least suggest making it a configurable option. |
Hello. Thanks for having a look at this.
|
@cmacmackin Hmm, I take your point. I can just rejig the templates a little to display the full doc for each binding on the type page only. I'll have to check to see if something similar happens to generic interfaces (and how generic type-bound procedures are displayed too). It does raise some other questions though -- should we be reporting the procedure names for the bindings if these are implementation details? For example, and only link to the specific procedure page if that is public? |
@HugoMVale I've fixed the "Read More" bit not working in #451 -- if you're able, would you mind just checking that works ok for you? I've got a couple of other small bits I want to get in, then I'll make a new release |
Hello @ZedThree. Just tried it on my computer and the full documentation of each public type-bound procedure is now completely displayed. Thanks!
There must be some sort of difference between |
That's very odd. In both cases, the component docstrings aren't displayed either, even though they're all documented. I'll investigate |
@HugoMVale Ok, I found it, FORD needs the name on the Because we work almost entirely off regular expressions, this is a bit tricky to do robustly, so the easiest fix is to add the type name at the end, so EDIT: The components not being visible is a separate issue that I'm still investigating |
Many thanks, @ZedThree ! |
Hello. First of all, let me thank you for this very helpful piece of software.
I noticed 2 issues related to derived data types and type-bound procedures:
Thanks!
The text was updated successfully, but these errors were encountered: