« first day (1851 days earlier)      last day (3096 days later) » 

3:00 AM
@Rapptz Hey I wanted to talk about your C++ doc thing
 
soup
 
do you like it?
 
I wrote it but I never used it.
I was thinking of supporting the napoleon type doc comments.
But iunno how to.
I should probably use it in a real project and not in a test file that tries to break it lol
I was writing some doc comments in python the other day and I realised how ugly and constricted the sphinx rst syntax could get
 
well that’s a shame, I’m not sure what to do now
 
y
what did you want to do
 
3:06 AM
write extractable comments, and then extract them
 
I mean it's not like my code is broken or anything
it works
 
Is there a proposal to make auto thing = T() or T{} legal even when T is neither movable nor copyable? I remember @Morwenn mentioning something like that.
 
ew special cases
 
>special cases
>C++
 
@GregorMcGregor I can’t imagine so
 
3:08 AM
fuck markdown
 
If you want the code I can gib luc
 
lucdoc
 
the only dependency is libclang
 
@Rapptz eh pass, it’s Doxygen-style comments right?
not to look a gift horse in the mouth but
 
iunno what that means
there's no doxygen directives or a bridge to support doxygen
that'd be 2mucheffort4me
 
3:10 AM
Oh right, comments are signalled with //< etc. other styles too but then you just get the text?
 
I support /** */ ///< and some other ones..
I had an image..
 
I’m really concerned about the markup in the comments
 
these..
Oh I just now realise the syntax
@LucDanton I wanted to write something with the sphinx event system so I can pass in a string to an event and then get back a transformed representation of said string
that way if I publish it or something people can write their own little parsers to convert their comments into the proper .rst (think napoleon plugin) but I never found out how to make it work
 
I think I’m desperate enough to try Breathe for the time being.
 
that uses doxygen markup
 
3:14 AM
yeah I’m curious about that since doxygen supports markdown
 
well how breathe works is that doxygen spits out a .xml and then breathe converts that into a .rst
 
right
 
napoleon is a lot more complicated than I gave it credit
 
implementation-side or user-side?
 
former
maybe the problem is more difficult than I thought
oh I see how it works now
that's dirty lmao
I forgot in params existed
 
3:20 AM
my god the documentation is bootstrapped
 
lol yeah
I noticed that too
 
@Rapptz cute
the ol' swaparoo
 
I have no idea why _skip_members is there
that looks like something that autodoc should do?
maybe I should support GoogleDoc as a built-in
except without the python-specific things
Actually I like NumPy better
looks nicer
I wonder if I could piggyback off of napoleon's work.
why deal with parsing myself if someone else already did it :v
 
@Rapptz Google-style drifts a lot to the right to the point that re-flowing that often annoys me
I like it better when reading though
 
I think the answer to my question is "maybe"
I think the answer has changed to "probably not"
it'd work but there's a lot of python specific things :<
 
3:42 AM
Damn. I played Icewind Dale again too much.
 
@Rapptz what happens if I turn off Doxygen support for Markdown and enable Napoleon?
 
whatcha mean?
Napoleon processes a list of strings composed of the docstring, I don't think breathe exposes that.
 
too bad, could have been funny
 
@LucDanton You will be transport to Elba.
 
anyway since I know how to expose this transformation API
it should be relatively simple to add a plugin that parses a C++ comment and then make it spit out proper .rst
C++ domain has some limitations though
I could send PRs to solve some of them
Like how there's nothing for template parameters like there is for params
 
3:47 AM
I thought you had already decided not to do that
 
that one is easy to PR
@LucDanton nah I just decided I can't piggyback off of the work that already went into napoleon because it uses python-domain-exclusive markup :<
e.g. :exc: and module-related stuff
 
No I mean from before you embarked on your own libclang thing
 
did I?
 
I remember most of the C++ domain work was maintained/done by a single contributor, and that turned you off it
i.e. he had enough on his plate already
 
Jakob is the man.
I don't think I'll ever speak ill of him or be turned off by that heh.
A lot of my issues and PRs get accepted anyway.
 
4:04 AM
Well I made a PR to support :tparam X: Some cool template.
 
@Borgleader How dare you accuse me of such a thing?
 
I’m not having much success with Breathe just yet
 
@JerryCoffin Your disappointment is palpable.
 
what's wrong with breathe?
 
4:16 AM
silly me, I was using doxygenclass when I should have been using doxygenstruct
 
lol what
atm my thing is kind of barebones
you can do .. inkfile:: "somefile.hpp"
but you can't be selective with what you want to do
 
I guess doxygen generates different XML depending on whether you use a class or struct class-key and then Breathe can’t find it if you use the wrong directive
 
e.g. .. inkclass:: whatever
 
now to figure out why it can’t find main, this time there is no doxygenmain
 
oh
that's a doxygen thing
you have to document the file first
 
4:19 AM
that does ring a bell
 
> The documentation of global functions, variables, typedefs, and enums will only be included in the output if the file they are in is documented as well.
So you have to do the noise of /** \file whatthefuckever **/
 
@Rapptz doesn’t seem to help
 
not sure then
that's what the manual says
 
yeah dw
I’ll take a break first though
 
4:26 AM
I’ll turn on HTML output and see what Doxygen does
 
@Rapptz massive changes right there
 
ye a truly revolutionary PR
 
also whoaaah they changed the design of the PR page
now it's full width and actually readable
incredible
 
hi @chmod
 
4:41 AM
> Someone building software in 2015 will have a much easier time than someone in 1998, because so much of the work has already been done for us.
Instead of writing complex JavaScript, we can use jQuery.
GOOD ANALOGY
 
Instead of using Windows XP, we use Windows 10.
 
it surprising how much javascript Microsoft used for things like tours and help screens (Windows XP tour, and the Windows 98 welcome application)
 
Fuck JavaScript
 
@GregorMcGregor 10/10 would analogy again
oooh it apparently first appeared in 1995
 
@R.MartinhoFernandes sorry, I just felt that I needed to provide that info.
 
4:50 AM
> TensorFlow comes with an easy to use Python interface and a no-nonsense C++ interface
lol since when is "no-nonsense C++ interface" a marketing feat
 
@GregorMcGregor they tried a 'senseless C++ interface' but that didn’t work out, so they threw out the stupid
 
Except as a software developer/engineer, you get paid relatively better in 1998 than 2015, and that's what really matters to the software developer/engineers ...
 
fact: in 1998 I was two years old.
 
5:12 AM
huh. The array_view and string_view in the GSL have been renamed to span and string_span, looks like.
 
wtf why is the pointer arg for ostream.write a T const * and not T const * const
and which version of the gsl does coliru have
 
makes no difference
 
all of these questions
...because one can be initialized from the other, the only issue with the two is when converting from T* to a const version of it. I suspect I need to go to bed
 
forget about pointers and start with int and int const
 
5:23 AM
but ints are not pointers!
 
that’s a feature
 
and I wasn't even thinking of T* but T**. Yes, definitely bedtime.
 
Funny how 3.f + 4.if is now legal C++.
If you have the using directive for complex literals.
 
So you mean 4.if is legal but 5.else isn't? scandal
 
Yeah, and 6.for is 6. ||
Or should be!
 
5:38 AM
> Dans le commerce équitable, on doit bien pouvoir trouver du miel éthique produit dans des ruches où les abeilles sont payées à juste titre et bénéficient de congés payées.
 
Dommage que la faute gâche tout.
> Au Burundi, « c’est un génocide qui a commencé ».
C'est la saison !
 
@GregorMcGregor je pense qu’il était en fait question de congères
@Rapptz Yep I do have documentation generated for the global things as expected, now to figure out how to refer to that with Sphinx
 
Did you know that the antipode of Noirmoutier lies somewhere in the sea east of New Zealand
And from HK it's somewhere in Bolivia
 
@GregorMcGregor yeah
'inflexible' is probably going to be my pet peeve here
bummer because that’s what I like about Sphinx
 
5:57 AM
yikes
 
> The function name, including namespace, is required to be unique in the project.
I have yet to investigate that also but that’s a lot of red flags popping up
 
My extension works very similar to autodoc
It just converts comments into .rst and lets sphinx handle the rest.
 
> SEVERE: Duplicate ID: "bar".
if I remove the cleverness that ignores .cpp files etc.
no overload support whatsoever
alright uninstall time
 
huh
C++ has overloading though
even Sphinx supports C++ overloading
 
the XML that doxygen outputs does have separate entries for the overloads, it’s Breathe that doesn’t bother
 
6:02 AM
wow this code is bad
but then I remember this is all libclang's fault
 
> The growth in courses available on the web has led to a growth in paid services that will impersonate students and do their work for them.
Getting paid to take courses sounds like a win-win :)
 
who has a self-contained file I can use to test out if my doc tool still works
 
otoh Doxygen doesn’t seem to handle e.g. expression SFINAE overloads very well, and that’s using libclang
garbage successfully removed from system
 
have you ever used the sphinx C++ domain
 
naw
 
6:14 AM
oh
I've used it for 3 projects
the referencing mechanism atm is 'broken'
 
the mangling thing?
 
Outside of that the sphinx C++ domain has gotten a looooooot better since jakob started maintaining it
it was broken in v1.2 and v1.3 made it usable and now in v1.4 there's full support for templates
 
oo
btw I don’t understand the example list
aaaa doesn't matter too much
@Rapptz so where are we with regards to your thing?
@Rapptz hey that’s not quite released yet
@Rapptz do you like it (assuming fix)?
 
@LucDanton My thing works.
There's some stuff I want to do with it though
Like supporting different comment markup
 
6:22 AM
and having things like .. inkclass:: x instead of just tossing the file.
 
@Rapptz elaborate pls?
 
You know how autodoc has ..autoclass:: x?
well my thing only has ..automodule:: x
 
oic
What’s 'tossing' the file?
 
bad terminology :p
 
So is reusing Napoleon’s e.g. GoogleDocstring a bad move do you think?
 
6:25 AM
supporting .. autoclass:: x is hard
C++ isn't as nice as Python when it comes to that stuff :<
 
here we are again with (quasi-)reflection
 
Nah not reflection.
Qualified names.
Like in Sphinx you can do .. currentmodule:: x and then do .. autoclass:: y instead of .. autoclass:: x.y
 
well
 
@LucDanton It would probably work but some sections would translate incorrectly.
One of the ones I saw that would definitely not work is things like "Raises" (C++ uses "Throws")
as in it's :raises X: in Python but :throws X: in C++
 
@Rapptz I’m stuck in the documentation, I see docs for :cpp:function: but not what goes in it
 
6:31 AM
function name
oh
function declaration
 
where does the :throws come from?
 
info list
 
I only see documentation for the Python domain
 
for some reason the info list isn't documented in the C++ domain
I can probably add a PR for that too..
there's :throw(s):, :return(s): and :param:
 
is there a good reason not to have :throws and :raises be aliases to the same underlying thing?
I see the JS domain uses that, too
no info list either but it has an example that uses it
 
6:34 AM
Napoleon should just use :throws X: instead of :raises X: because iirc the python domain supports it too
nope
GroupedField('exceptions', label=l_('Raises'), rolename='exc',
                     names=('raises', 'raise', 'exception', 'except')
both C++ and Python do support :exception X:
so that'd be the common ground
 
that’s… weird, no?
 
yeah lol
JS only has :throws:
but seriously the parser for napoleon looks pretty complex lol
 separator = has_desc and ' -- ' or ''
 
napooleon
 
wot
 
' -- ' if has_desc else ''
it’s a Perl-ism
 
6:39 AM
wow that's hard to read for me
what's wrong with the conditional statement
lol
 
@Rapptz wasn’t in early Perl
 
well I mean for the python code...
I wonder what version that construct was added
 
I think it’s actually fairly recent-ish
 
v2.5
 
somehow I never trip up over the x and y or z nonsense even though I nearly never write things like that (exception being in Lua), but the y if x else z thing still trips me up even though I’ve now written it plenty of times
 
6:42 AM
released in 2005 I think
2006
 
otoh I keep wishing I could do blaf if foo
which is also a Perl-ism…
 
@LucDanton I think it reads nicely.
I didn't like it at first but it kinda grew on me
 
I’ve never written Perl in my life
 
I think the reason why the parser is complicated is because despite being called "GoogleDocstring" it actually parses both types
the Numpy one just subclasses the Google one
 
smart
it still does different things, somehow
'meth': 'meth',
of course
 
6:45 AM
so which one do you prefer?
google or numpy?
 
google right?
 
Google, but not by much
 
noople
 
in the end I kinda only really care about the rendered result
I tried integrating help in my Python workflow but meh
I prefer a nice, larger picture page than an individual docstring (which is why we’re talking about Sphinx, too)
 
6:47 AM
lemme pass in one of my files from Gears
see if it breaks
 
I don’t think I have any comment to feed it
502 open issues, they sure need the help
 
D:\GitHub\inkdoc\tests\index.rst:9: ERROR: D:\GitHub\inkdoc\math.hpp:168:20: no type named 'sqrt' in namespace 'std'
:ok:
lol that is indeed my fault
how'd this even compile
I forgot <cmath>
 
squirt harder
it completely went over my head that you can still put rst in docstrings with Napoleon
well, it’s a hack of course
block = ['.. code-block:: python', '']
 
Output is fine.
 
there are hardcoded things in there
 
6:54 AM
I need to add like an override
for the signatures like how autodoc does..
...yeah
 
pretty!
sadly when I looked there is no class for the return type :/
 
lol that definition for max
 
the constexpr and typename etc. are specifiers or attributes or whatever and are stylable
tangent
 
@GregorMcGregor it's fine :v
fight me
 
with concepts do you think template<typename... Args> blah blah max(Args&&... args) requires something; is nicer than 'peeling' off the pack?
 
6:57 AM
I was thinking of having doc comment specific options
 
strictly from the pov of user-facing signatures, not for ease of writing an implementation
 
@Rapptz I'm not saying it's bad
 
like something like @signature <sig override here>
if it's in a single line
but iunno might be a terrible idea
 
It's just hilarious
WTB requires sizeof...(Args) >= 2
 
@Rapptz I know that’s a feature I wouldn’t use because I would be too afraid it becomes out-of-sync with the code
I’m actually wary of things like that in doc comments
that’s not to say it’s not of benefit to someone out there
@GregorMcGregor is that an answer to my tangential question?
 

« first day (1851 days earlier)      last day (3096 days later) »