Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Mar 12 10:08
    SuperOP535 closed #92
  • Jan 13 21:26
    rom1504 commented #95
  • Jan 13 18:12
    rom1504 opened #96
  • Jan 13 18:11
    rom1504 opened #95
  • Nov 29 2018 20:42

    rom1504 on master

    Change some functions to arrow … (compare)

  • Nov 29 2018 20:42
    rom1504 closed #94
  • Nov 29 2018 20:33
    SuperOP535 synchronize #94
  • Nov 29 2018 20:31
    SuperOP535 synchronize #94
  • Nov 29 2018 20:29
    SuperOP535 opened #94
  • Nov 29 2018 18:31
    SuperOP535 closed #93
  • Nov 29 2018 08:56
    SuperOP535 opened #93
  • Nov 25 2018 15:53

    rom1504 on master

    update chat badges (compare)

  • Nov 15 2018 13:29
    SuperOP535 opened #92
  • Nov 15 2018 13:23
    SuperOP535 commented #75
  • Nov 15 2018 11:18
    rom1504 commented #75
  • Nov 15 2018 10:18
    SuperOP535 commented #75
  • Nov 13 2018 01:17
    rom1504 commented #75
  • Nov 12 2018 23:19
    rom1504 closed #85
  • Nov 12 2018 23:19
    rom1504 commented #85
  • Nov 12 2018 23:19

    rom1504 on master

    Added LICENSE file (compare)

William Gaylord
@wgaylord
as no one said anything.
Robin Lambertz
@roblabla
@chibill IDK. No one knows. I don't remember how mapper works, I'd need to dig into the source code of the mapper datatype. And I'm not too interested in knowing.
Mapper sucks and should die :P
@hansihe aaah I see. I missed the ref somehow
Makes sense now
Hans Elias J.
@hansihe
chibill: mapper is two way. it maps a string to a constant
Robin Lambertz
@roblabla
Last question : what does virtual do in containers ? Is it to signify that it contains virtual fields ?
William Gaylord
@wgaylord
so why is it not that way in the impl? or is JS goofy syntax messing me up......
Hans Elias J.
@hansihe
so when reading it could take 0 and map it to something like "packet_read"
when writing it would take "packet_read" and map it to 0
switch is not capable of doing that
Robin Lambertz
@roblabla
It could
NVM
it can't.
My brain is not working
Hans Elias J.
@hansihe
roblabla: when a container only has a single non-virtual field in it, you can mark the container as virtual
that removes the container from the output, the single non-virtual field replaces it in the serialized/deserialized data
Robin Lambertz
@roblabla
ah, so it's like the old anon ?
William Gaylord
@wgaylord
but would the non-virtual field not then be virtual? Unless there is a non-virtual tag or something on the field....
Robin Lambertz
@roblabla
kinda sorta
Hans Elias J.
@hansihe
no, not really
well, the other way around kinda
Robin Lambertz
@roblabla
hmm, yeah I get it
Hans Elias J.
@hansihe
it's a way of defining something like a length prefixed array type without specific built in language features
William Gaylord
@wgaylord
how does it know that the field is not virtual along with the container?
Hans Elias J.
@hansihe
it just helps with composability really
Robin Lambertz
@roblabla
@chibill virtual just means you don't provide it data directly
instead it is derived from another field.
Hans Elias J.
@hansihe
chibill: notice that there are fields and there are virtual_fields? fields are not virtual, virtual_fields are virtual
Robin Lambertz
@roblabla
E.G. when writing, you don't have to specify the length of an array yourself. That's because "count" is a virtual field.
William Gaylord
@wgaylord
so why not have virtual_container?
Robin Lambertz
@roblabla
valid question.
Hans Elias J.
@hansihe
because the container has the exact same semantics when specifying types wither it is virtual or not
William Gaylord
@wgaylord
Also I did not notice virtual_field because its not in the example.
Hans Elias J.
@hansihe
but yeah, that's a design decision
Robin Lambertz
@roblabla
@chibill it is
in the pds
Hans Elias J.
@hansihe
yep
look for it
it's there
Robin Lambertz
@roblabla
virtual_field is just "virtual" in the JSON
which is interesting...
William Gaylord
@wgaylord
so why not just add virtual into the type args... As thats what it will be in the json...
why make a new type?
Robin Lambertz
@roblabla
It's not really a new type
it replaces count
and makes it more generic
William Gaylord
@wgaylord
virtual_field is a new type if you look how the pds is. Each type is defined by a syntax like <type>()
But its a type that only exists in the pds