Magnus

Results 94 comments of Magnus

> Is this so that you don't have to wrap external types in a new type? Not exactly. I sometimes encounter the following scenario. Imagine a `compute` crate, which exposes...

> But again, that's not completely optimal either. We should probably support something similar to what they are doing in our macros. Do have something in mind for that? As...

@sunny-g were you able to make progress?

> Can you give me some feedback whether I'm on the right track? This looks like the right approach to me. Is something missing? How does it interact with lifetimes?

> Ping @evnu ;) Do you plan to complete #430 first and then we take a look into this PR here again?

@turion can you rebase on master?

> I'm not even sure, maybe generic types are already handled now? [ We will have to try how well](https://github.com/rusterlium/rustler/pull/483) adds generic types, but maybe we need to test this...

@elbow-jason Thanks for finding this! Some additional info when running this with a debug build of ERTS and valgrind (rustc 1.39.0 (4560ea788 2019-11-04), Elixir 1.9.4, Erlang/OTP 22 [erts-10.6]) : ```...

GDB for the coredump indeed indicates an endless loop: ``` gdb) bt #0 0x00007f69fbf454ab in ::decode () from /tmp/why_sig_bus/_build/dev/lib/why_sig_bus/priv/native/libwhysigbus_native.so #1 0x00007f69fbf4551f in ::decode () from /tmp/why_sig_bus/_build/dev/lib/why_sig_bus/priv/native/libwhysigbus_native.so #2 0x00007f69fbf4551f in ::decode...

For simple cases, Rust will warn on endless recursion. Apparently, it cannot detect the recursion in this case here. See this [playground](https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=a855b94982c4a67e14698a2e01b95970) example for a simple case which is detectable....