On Wed, Dec 5, 2018 at 6:04 AM Ole Troan <otr...@employees.org> wrote:
> All, > Hi Ole, > Here is an update on API progress. > > In the long process of making types in the API language more explicit I > have a few changes merged and a few in the pipeline: > Hooray! > - Type aliases. Previously any new user defined type had to be a > structure. With type aliasing one can do > e.g. > typedef u32 interface_index > instead of: > typedef { > u32 index; > } interface_index; > > This is merged in 53fffa1d > > I have a similar change for the relatively new ip4_address and ip6_address > types, so instead of: > typedef { > u32 address[4]; > } ip4_address; > > That is now: typedef u32 ip4_address[4]; > And we mean s/u32/u8/ here, right? :-) > I will try to update the API definitions with new type as I get the > chance. bool and type aliases are backwards compatible (in that they > require no change on the VPP side). > [ ... ] Any other changes you’d like in the API language? > I noticed that we had f64, but not f32 the other day. Is that by accident or choice? Related, it might be nice to have the clib_host_to_net_f{32,64}() functions too? (We are apparently doing those as clib_host_to_net_u64() and casting them to f64 now.) And please let me know if you have comments on the above. > > Cheers, > Ole > Pedantically, jdl
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#11514): https://lists.fd.io/g/vpp-dev/message/11514 Mute This Topic: https://lists.fd.io/mt/28610110/21656 Group Owner: vpp-dev+ow...@lists.fd.io Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-