profile
viewpoint
Marcel Hellwig hellow554 Hamburg, Germany

hellow554/cursive_hexview 13

A simple hexview for cursive

hellow554/logical-rs 5

A Ieee1164 digital circuit network simulator

hellow554/anymap 0

A safe and convenient store for one value of each type

hellow554/at24cx-rs 0

Platform agnostic driver for AT24CX series serial EEPROM written in Rust and built using embedded-hal

hellow554/backtrace-rs 0

Backtraces in Rust

hellow554/bayespam 0

A simple bayesian spam classifier, written in Rust.

hellow554/BoringAuth 0

Straightforward password, passphrase, TOTP, and HOTP user authentication

hellow554/byteorder 0

Rust library for reading/writing numbers in big-endian and little-endian.

hellow554/cargo-bisect-rustc 0

Bisects rustc, either nightlies or CI artifacts

hellow554/ClanLib 0

ClanLib is a cross platform C++ toolkit library.

issue commentkumavale/sisterm

Line won't get redrawn

telnet doesn't work either, but something funny is happening (in normal mode and telnet mode)

yoyoyo2

I don't know if this is a problem with the powershell as well, but when I just press the spacebar, the line gets adjusted just right, but not when typing in characters.

hellow554

comment created time in 18 hours

CommitCommentEvent

issue commentkumavale/sisterm

Line won't get redrawn

I'm indeed using the windows terminal with the powershell inside.

According to https://docs.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences#cursor-positioning it does indeed support the ^[y;xH escape sequence and inside the powershell itself, everything works finde when using the home key.

hellow554

comment created time in 2 days

startedkumavale/sisterm

started time in 2 days

issue openedkumavale/sisterm

Arrow keys not working properly in pager (e.g. less)

When I connect via the serial line to a linux device and open something in a pager (e.g. journalctl which uses less by default), I can't use the arrow keys to navigate left, right up or down.

In the normal bash, it works flawlessly, but inside of less it doesn't work. It works however with tera term, so I guess there's something wrong.

Funny enough, <kbd>Page Up</kbd> and <kbd>Page Down</kbd> work, as well as <kbd>j</kbd>/<kbd>k</kbd>

created time in 2 days

issue commentkumavale/sisterm

Line won't get redrawn

yoyoyo

Here's a gif for you ;)

hellow554

comment created time in 2 days

issue commentkumavale/sisterm

Line won't get redrawn

The home key is actually a [8, 8, 8, 8] but is truncated because of the home key itself?!

hellow554

comment created time in 2 days

issue commentkumavale/sisterm

Line won't get redrawn

[Char('l')][108]l[Char('s')][115]s[Char(' ')][32] [Char('/')][47]/[Home][8, 8, 8[Right][108]l[Right][115]s[Char(' ')][32, 32, 47, 8, 8] [Char('-')][27, 91, 52, 104, 32, 27, 91, 52, 108, 8, 45]-[Char('l')][27, 91, 52, 104, 32, 27, 91, 52, 108, 8, 108]l[Char('h')][27, 91, 52, 104, 32, 27, 91, 52, 108, 8, 104]h[Char('a')][27, 91, 52]104, 32, 27, 91, 52, 108, 8, 97]ha[Char('\r')][13, 10]

this was <kbd>l</kbd><kbd>s</kbd><kbd> </kbd><kbd>/</kbd><kbd>Home</kbd><kbd>→</kbd><kbd>→</kbd><kbd> </kbd><kbd>-</kbd><kbd>l</kbd><kbd>h</kbd><kbd>a</kbd><kbd>Enter</kbd>

hellow554

comment created time in 2 days

issue commentkumavale/sisterm

Line won't get redrawn

Yes I do expect that exact behavoir you are showing in your gif. Weird, that it doesn't work for me.

I have a COM connection via a FTDI serial cable to a linux system. Any chance I could provide my data to you why it isn't working?

It does work in tera term for example.

hellow554

comment created time in 2 days

issue openedkumavale/sisterm

Line won't get redrawn

If I type a line and i use (either the arrow keys or the home key) to get to a different location in that line and start typing, the characters are overwriting the previous one, without the line to be redrawn.

This look similar to this:

grafik

but should look like

grafik

<!-- mad paint skillz :D -->

created time in 3 days

issue openedkumavale/sisterm

ctrl+arrow keys not working

Thanks for the huge last update, which makes the home, end keys work.

For a better bash experience now the ctrl+arrow keys are missing (at least under windows in powershell).

created time in 3 days

issue openedPokeAPI/pokepy

How to deal with subresources

e.g.

pokepy.V2Client().get_generation(1).pokemon_species[0]

is a NamedApiResource which points to PokemonSpecies

I haven't figured out yet, how to get the data from that NamedApiResource. Is there an easy way, e.g. get()?

created time in 5 days

issue commentMicrosoftDocs/WSL

WSL2 breaks VirtualBox 6.1

Nope, I also have the problem and I use an i7-10750H, so it's not an AMD exclusive problem

jlearman

comment created time in 8 days

issue openedfmtlib/fmt

Alternate form for strings (and similar)

An alternate form for strings, which does print the escape sequences as string, instead of interpreting them would be nice, e.g.:

auto s = "Diz\r\"Iz\"\n'a'\tString";
fmt::print("{}", s); // 
fmt::print("{:#}", s);

would print

Diz
"Iz"
'a'	String
"Diz\r\"Iz\"\n\'a\'\tString"

What is your oppinion on this? This would help debugging strings, because the escape sequences will be printed directly

created time in 8 days

pull request commentrust-embedded/gpio-cdev

Crates.io now enforces a max of five keywards

This is sad and confusing to me. At least the libgpiod keyword could have been left. Then it would be 5.

posborne

comment created time in 9 days

delete branch hellow554/safe

delete branch : patch-1

delete time in 15 days

PR opened LouisCharlesC/safe

replace module_path with current_list_dir

https://github.com/LouisCharlesC/safe/blob/2f24b6f1b4a4467abb68458deb77e82835ce5f92/cmake/InstallTarget.cmake#L7-L11

This uses ${CMAKE_MODULE_PATH} which contains in my case a semicolon seperated list of files, and this seems to be correct.

| CMake Error: File /home/marcel/y_unic/build/tmp/work/cortexa7t2hf-neon-vfpv4-mut-linux-gnueabi/safe/1.0.1-r0/recipe-sysroot/usr/share/cmake/Modules/;/home/marcel/y_unic/build/tmp/work/cortexa7t2hf-neon-vfpv4-mut-linux-gnueabi/safe/1.0.1-r0/recipe-sysroot/usr/share/cmake/Modules/;/home/marcel/y_unic/build/tmp/work/cortexa7t2hf-neon-vfpv4-mut-linux-gnueabi/safe/1.0.1-r0/git/cmake/safeConfig.cmake.in does not exist.
| CMake Error at /home/marcel/y_unic/build/tmp/work/cortexa7t2hf-neon-vfpv4-mut-linux-gnueabi/safe/1.0.1-r0/recipe-sysroot-native/usr/share/cmake-3.15/Modules/CMakePackageConfigHelpers.cmake:330 (configure_file):
|   configure_file Problem configuring file
| Call Stack (most recent call first):
|   cmake/InstallTarget.cmake:7 (configure_package_config_file)
|   CMakeLists.txt:17 (include)

Using CMAKE_CURRENT_LIST_DIR fixes it, because that variable contains the cmake subfolder which also contains the safeConfig.cmake.in file.

+2 -2

0 comment

1 changed file

pr created time in 16 days

push eventhellow554/safe

Marcel Hellwig

commit sha e8adc7358c43ef518ef617c723f64424e6e79f9b

replace module_path with current_list_dir module_path contains a semicolon seperated list of paths to search in. This is why cmake isn't able to find the `safeConfig.cmake.in` in my case. The `CMAKE_CURRENT_LIST_DIR` holds the value of the current directory the cmake file is executed in. This means, that the `safeConfig.cmake.in` needs to reside in the same directory as the InstallTarget file, but this is the case and therefore shouldn't be a problem.

view details

push time in 16 days

fork hellow554/safe

C++11 header only wrapper for mutexes and locks.

fork in 16 days

issue commentrust-embedded/meta-rust-bin

How to specify a certain version of rustc

Thanks! Would this something for the readme?

hellow554

comment created time in a month

issue openedrust-embedded/meta-rust-bin

How to specify a certain version of rustc

What information should I include in my recipe, do tell yocto which version of rust it should use? E.g. I want my code to compile with Rust 1.43.0, (e.g. because of a regression).

created time in a month

issue openedkumavale/sisterm

Home, End, PageUp, PageDown keys not working properly in Powershell

I'm using sisterm to connect to a linux device using a serial cable. When I'm using bash, the four keys are not working properly

<kbd>Home</kbd> produces G <kbd>End</kbd> prodocues O <kbd>PageUp</kbd> produces I (uppercase i) <kbd>PageDown</kbd> produces Q

I know (I'm relatily sure) that cursive handles such keys right with the termion crate.

Would that be an option instead of the plain _getch?

created time in a month

startedkumavale/sisterm

started time in a month

issue commentedc/bass

`$1` is set in contrast to bash

Funny enough, when I type

fish ~/.local.share/omf.pkg/bass/functions/bass.fish source a.sh the output is empty as well like bash would do. That's something beyond my paygrade ;)

hellow554

comment created time in a month

issue openededc/bass

`$1` is set in contrast to bash

a.sh:

echo $1

bash -c 'source a.sh'

bass source a.sh

source a.sh

This confuses some scripts which might accept an optional argument (in my case it's the poky script from yocto)

created time in a month

Pull request review commentsnapview/tungstenite-rs

Some simplifications

 mod string_collect {             let mut input: &[u8] = tail.as_ref();              if let Some(mut incomplete) = self.incomplete.take() {-                let fin = if let Some((result, rest)) = incomplete.try_complete(input) {+                if let Some((result, rest)) = incomplete.try_complete(input) {                     input = rest;                     if let Ok(text) = result {                         self.data.push_str(text);                     } else {                         return Err(Error::Utf8);                     }-                    true                 } else {                     input = &[];-                    false-                };-                if !fin {                     self.incomplete = Some(incomplete)-                }+                };

You could/should move the ; to the ... = Some... line

phimuemue

comment created time in a month

PullRequestReviewEvent

Pull request review commentsnapview/tungstenite-rs

Some simplifications

 mod string_collect {             let mut input: &[u8] = tail.as_ref();              if let Some(mut incomplete) = self.incomplete.take() {-                let fin = if let Some((result, rest)) = incomplete.try_complete(input) {+                if let Some((result, rest)) = incomplete.try_complete(input) {                     input = rest;                     if let Ok(text) = result {                         self.data.push_str(text);                     } else {                         return Err(Error::Utf8);                     }-                    true                 } else {                     input = &[];-                    false-                };-                if !fin {                     self.incomplete = Some(incomplete)-                }+                };

Is that ; necessary?

phimuemue

comment created time in a month

PullRequestReviewEvent

startedsnapview/tungstenite-rs

started time in a month

issue commentrust-embedded/meta-rust-bin

cross compiling using bindgen under x86_64, but requires 32 bit

It seems to me, that he uses my systems /usr/include/linux/types.h file, instead of the sysroot ones. Is that possible? I don't think, that that is inteded, right?

sprhawk

comment created time in a month

issue commentrust-embedded/meta-rust-bin

cross compiling using bindgen under x86_64, but requires 32 bit

Same issue here 🙋

In my case, I have a program, that depends on socketcan-alt, which uses bindgen, to produce bindings for the <can.h> header.

Here's the error message for me (which is somewhat similar to @sprhawk s)

| error: failed to run custom build command for `socketcan-alt v0.2.2 (https://github.com/Hakuyume/socketcan-rs.git?rev=f79cef958e7f4ec68ee1e0f30a7b66df15411ad6#f79cef95)`
| 
| Caused by:
|   process didn't exit successfully: `/home/op/y_unic/build/tmp/work/cortexa7t2hf-neon-vfpv4-mut-linux-gnueabi/emv-test/1.0-r0/target/release/build/socketcan-alt-31d2e4f812a3f006/build-script-build` (exit code: 101)
|   --- stderr
|   /usr/include/linux/types.h:5:10: fatal error: 'asm/types.h' file not found
|   /usr/include/linux/types.h:5:10: fatal error: 'asm/types.h' file not found, err: true

I'm building for an arm device, so like sprhawk not for the same platform. Maybe that's the issue?

A question, which you might be able to answer: What target is bindgen aiming at? The host or target platform, when he's looking for the <linux/can.h> file (e.g. does he try to use the recipe-sysroot or recipse-sysroot-native directory?)

sprhawk

comment created time in a month

PR opened rust-embedded/gpio-cdev

Add `libgpio`, `libgpiod` and `gpiod` to keywords

The reason is, that I didn't find this crate until I was very desperate and only stumpled upon it by this comment.

Even today if I google rust "libgpiod" I can't find this place.

I often try to google the c library counterpart together with the keyword rust to see if I can find something that suits my needs. This crate does, however it's not easy to find.

Maybe this PR can be extended to update the README.md and mention it there as well.

+1 -1

0 comment

1 changed file

pr created time in 2 months

push eventhellow554/gpio-cdev

Marcel Hellwig

commit sha 1a0c1d415d35f04abf0d488da9c3ddcf241bf446

Add `libgpio`, `libgpiod` and `gpiod` to keywords For a better finding of this crate

view details

push time in 2 months

fork hellow554/gpio-cdev

Rust interface to the Linux GPIO Character Device API (/dev/gpiochip...)

fork in 2 months

startediolivia/rust-sokoban

started time in 2 months

fork hellow554/imx_usb_loader

USB & UART loader for i.MX5/6/7/8 series

fork in 3 months

issue openedthecodeflayer/alttp-tracker

Reasoning behind decrementing keys

I'm somewhat confused why clicking on a key counts downwards. If I'm for example in Keysanity mode I want to track the amount of keys I already collected.

So, what's the reason? Is there a Chance to add an Option to increment keys in click?

created time in 3 months

push eventhellow554/rust

bors

commit sha 4825e12fc9c79954aa0fe18f5521efa6c19c7539

Auto merge of #74578 - ehuss:fix-rust-src, r=Mark-Simulacrum Fix rust-src component. The rust-src component could not be installed by rustup because it included some symbolic links. #74520 added the backtrace directory which included some symlinks. Since the rust-src component doesn't need most of the files in the `backtrace` submodule, this changes it to only include the minimum necessary. Tested with cargo's build-std that it can build from the resulting tarball. Fixes #74577

view details

Aaron Hill

commit sha ac9dfc3e7785c9bba96ebac4fd51726189e1bf91

Normalize opaque types when converting `ParamEnv` to `Reveal::All` Fixes #65918

view details

Aaron Hill

commit sha 117a60e1f5045e317d3f76ce60be28d18c694608

Erase regions in try_eval_bits

view details

Aaron Hill

commit sha 90aee14eb95ac0b9ddb7cf5db6d003155e94800c

Skip computing param_env and size if not needed

view details

Aaron Hill

commit sha 5e2e927e0107916b825b164c82be44877ac6ab54

Fix rebase fallout

view details

Yuki Okushi

commit sha 430bd39a0da2b17e5c7ca4842e25b7f523c51522

Do not ICE on assoc type with bad placeholder

view details

Trevor Spiteri

commit sha d6cf128b45b4e7b370357b9497d68426719b0d5a

mark methods as constant since 1.47.0 instead of 1.46.0

view details

bors

commit sha e22b61bff0bdd08be7665607cb7be3748c8a35d2

Auto merge of #73270 - dylanmckay:avr-use-correct-addrspace, r=nagisa [AVR] Correctly set the pointer address space when constructing pointers to functions NOTE: Pull request iterations: * https://github.com/dylanmckay/rust/releases/tag/avr-use-correct-addrspace.0 * https://github.com/dylanmckay/rust/releases/tag/avr-use-correct-addrspace.1 * https://github.com/dylanmckay/rust/releases/tag/avr-use-correct-addrspace.2 This patch extends the existing `type_i8p` method so that it requires an explicit address space to be specified. Before this patch, the `type_i8p` method implcitily assumed the default address space, which is not a safe transformation on all targets, namely AVR. The Rust compiler already has support for tracking the "instruction address space" on a per-target basis. This patch extends the code generation routines so that an address space must always be specified. In my estimation, around 15% of the callers of `type_i8p` produced invalid code on AVR due to the loss of address space prior to LLVM final code generation. This would lead to unavoidable assertion errors relating to invalid bitcasts. With this patch, the address space is always either 1) explicitly preserved from the input type, or 2) explicitly set to the instruction address space because the logic is dealing with functions which must be placed there, or 3) explicitly set to the default address space 0 because the logic can only operate on data space pointers and thus we keep the existing semantics of assuming the default, "data" address space.

view details

Bastian Kauschke

commit sha c74c6486023899e0e2a1669fa4e32b8f62e1f97f

const prop into operands

view details

Pietro Albini

commit sha ffd112250e254a46255ebc7e94c7e9a9a7d9c905

ci: disable Azure Pipelines except for macOS

view details

Xavier Denis

commit sha 711a6807a7979715d6b2940db56eaf1585d30a71

Optimize away BitAnd and BitOr when possible

view details

Bastian Kauschke

commit sha d257bacfea8a046c41d6841f897d17944f2f0e64

note LLVM in fixme

view details

Mark Rousskov

commit sha 747bc8ec88b94ddfbd665d21bb87732411bcd1f7

Enable perf try builder This adds a dedicated branch for perf to use for CI, intended to allow perf to enqueue builds without needing to use bors. bors is great, but bors requires an open PR to work, and we want to invoke perf on closed PRs sometimes (in particular, rollups).

view details

Mark Rousskov

commit sha 744240678371b631b10d564201821f10d3baa72c

Revert "update backtrace-rs" This reverts commit 4cbd265c119cb1a5eb92e98d2bb93466f05efa46.

view details

Mark Rousskov

commit sha 3c6003c4c0505381544c03b9b9f0f697c002dd67

Revert "std: Fix compilation without backtrace feature" This reverts commit 028f8d7b85898683b99e05564cd2976c7e0d5b43.

view details

Mark Rousskov

commit sha cc4f547cf4a6bbeb7260077aca26be88644cb019

Revert "std: Switch from libbacktrace to gimli" This reverts commit 13db3cc1e8d2fd4b8e7c74d91002274d7b62801b.

view details

Mark Rousskov

commit sha b747a33abdf4c9d21b604853bc6dee105e622209

Revert "include backtrace folder in rust-src component" This reverts commit d7a36d8964c927863faef5d3b42da08f37e5896c.

view details

bors

commit sha 69d68f90964a46e479eec02a4d9c45aaaa45b411

Auto merge of #74620 - rust-lang:remove-most-azure, r=Mark-Simulacrum Disable Azure Pipelines except for macOS Following up on https://github.com/rust-lang/rust/pull/74565, this PR disables most of Azure Pipelines except for macOS auto builds, practically switching us to GitHub Actions :tada: r? @Mark-Simulacrum

view details

Vadim Petrochenkov

commit sha 49b9a6486ab0814f4c7d57c22c75216fdc1ebf14

rustc_target: Add a target spec option for disabling `--eh-frame-hdr`

view details

David Wood

commit sha 90e941a974e3561efa18c148de24db1f401cd3c4

mir: improve polymorphic constant bug This commit changes the span and content of the "collection encountered polymorphic constant" bug in monomorphization collection to point to the use of the constant rather than the definition. Signed-off-by: David Wood <david@davidtw.co>

view details

push time in 3 months

pull request commentrust-lang/rust

deny(unsafe_op_in_unsafe_fn) in libstd/process.rs

Resolved the merge conflict, but I'm still not sure what to write about the safety. I just copied the comments found in library/std/src/fs.rs and library/std/src/tcp.rs

hellow554

comment created time in 3 months

push eventhellow554/rust

bors

commit sha 4825e12fc9c79954aa0fe18f5521efa6c19c7539

Auto merge of #74578 - ehuss:fix-rust-src, r=Mark-Simulacrum Fix rust-src component. The rust-src component could not be installed by rustup because it included some symbolic links. #74520 added the backtrace directory which included some symlinks. Since the rust-src component doesn't need most of the files in the `backtrace` submodule, this changes it to only include the minimum necessary. Tested with cargo's build-std that it can build from the resulting tarball. Fixes #74577

view details

Aaron Hill

commit sha ac9dfc3e7785c9bba96ebac4fd51726189e1bf91

Normalize opaque types when converting `ParamEnv` to `Reveal::All` Fixes #65918

view details

Aaron Hill

commit sha 117a60e1f5045e317d3f76ce60be28d18c694608

Erase regions in try_eval_bits

view details

Aaron Hill

commit sha 90aee14eb95ac0b9ddb7cf5db6d003155e94800c

Skip computing param_env and size if not needed

view details

Aaron Hill

commit sha 5e2e927e0107916b825b164c82be44877ac6ab54

Fix rebase fallout

view details

Yuki Okushi

commit sha 430bd39a0da2b17e5c7ca4842e25b7f523c51522

Do not ICE on assoc type with bad placeholder

view details

Trevor Spiteri

commit sha d6cf128b45b4e7b370357b9497d68426719b0d5a

mark methods as constant since 1.47.0 instead of 1.46.0

view details

bors

commit sha e22b61bff0bdd08be7665607cb7be3748c8a35d2

Auto merge of #73270 - dylanmckay:avr-use-correct-addrspace, r=nagisa [AVR] Correctly set the pointer address space when constructing pointers to functions NOTE: Pull request iterations: * https://github.com/dylanmckay/rust/releases/tag/avr-use-correct-addrspace.0 * https://github.com/dylanmckay/rust/releases/tag/avr-use-correct-addrspace.1 * https://github.com/dylanmckay/rust/releases/tag/avr-use-correct-addrspace.2 This patch extends the existing `type_i8p` method so that it requires an explicit address space to be specified. Before this patch, the `type_i8p` method implcitily assumed the default address space, which is not a safe transformation on all targets, namely AVR. The Rust compiler already has support for tracking the "instruction address space" on a per-target basis. This patch extends the code generation routines so that an address space must always be specified. In my estimation, around 15% of the callers of `type_i8p` produced invalid code on AVR due to the loss of address space prior to LLVM final code generation. This would lead to unavoidable assertion errors relating to invalid bitcasts. With this patch, the address space is always either 1) explicitly preserved from the input type, or 2) explicitly set to the instruction address space because the logic is dealing with functions which must be placed there, or 3) explicitly set to the default address space 0 because the logic can only operate on data space pointers and thus we keep the existing semantics of assuming the default, "data" address space.

view details

Bastian Kauschke

commit sha c74c6486023899e0e2a1669fa4e32b8f62e1f97f

const prop into operands

view details

Pietro Albini

commit sha ffd112250e254a46255ebc7e94c7e9a9a7d9c905

ci: disable Azure Pipelines except for macOS

view details

Xavier Denis

commit sha 711a6807a7979715d6b2940db56eaf1585d30a71

Optimize away BitAnd and BitOr when possible

view details

Bastian Kauschke

commit sha d257bacfea8a046c41d6841f897d17944f2f0e64

note LLVM in fixme

view details

Mark Rousskov

commit sha 747bc8ec88b94ddfbd665d21bb87732411bcd1f7

Enable perf try builder This adds a dedicated branch for perf to use for CI, intended to allow perf to enqueue builds without needing to use bors. bors is great, but bors requires an open PR to work, and we want to invoke perf on closed PRs sometimes (in particular, rollups).

view details

Mark Rousskov

commit sha 744240678371b631b10d564201821f10d3baa72c

Revert "update backtrace-rs" This reverts commit 4cbd265c119cb1a5eb92e98d2bb93466f05efa46.

view details

Mark Rousskov

commit sha 3c6003c4c0505381544c03b9b9f0f697c002dd67

Revert "std: Fix compilation without backtrace feature" This reverts commit 028f8d7b85898683b99e05564cd2976c7e0d5b43.

view details

Mark Rousskov

commit sha cc4f547cf4a6bbeb7260077aca26be88644cb019

Revert "std: Switch from libbacktrace to gimli" This reverts commit 13db3cc1e8d2fd4b8e7c74d91002274d7b62801b.

view details

Mark Rousskov

commit sha b747a33abdf4c9d21b604853bc6dee105e622209

Revert "include backtrace folder in rust-src component" This reverts commit d7a36d8964c927863faef5d3b42da08f37e5896c.

view details

bors

commit sha 69d68f90964a46e479eec02a4d9c45aaaa45b411

Auto merge of #74620 - rust-lang:remove-most-azure, r=Mark-Simulacrum Disable Azure Pipelines except for macOS Following up on https://github.com/rust-lang/rust/pull/74565, this PR disables most of Azure Pipelines except for macOS auto builds, practically switching us to GitHub Actions :tada: r? @Mark-Simulacrum

view details

Vadim Petrochenkov

commit sha 49b9a6486ab0814f4c7d57c22c75216fdc1ebf14

rustc_target: Add a target spec option for disabling `--eh-frame-hdr`

view details

David Wood

commit sha 90e941a974e3561efa18c148de24db1f401cd3c4

mir: improve polymorphic constant bug This commit changes the span and content of the "collection encountered polymorphic constant" bug in monomorphization collection to point to the use of the constant rather than the definition. Signed-off-by: David Wood <david@davidtw.co>

view details

push time in 3 months

issue openedHakuyume/socketcan-rs

Splitting the crate into a sys and a high level crate

Currently, there's a lot of low level stuff going on in the API, for example passing a CString as an argument for the device. Also a lot of unsafe places are around.

To circumvent this, people tend to create a -sys crate and on top of that they build a rusty interface.

E.g. https://crates.io/crates/rusb depends on https://crates.io/crates/rusb

This way you could split up the build.rs and sys.rs thingy into its own crate and build on top of that a better API, that would accept a &str for example.

There are a few scary places that I can't get my head of, and sadly miri can't help here either, because of the libc calls.

What do you think about this? Is that something you want to spend your time on? Do you want help for that? What is your goal with this crate?

created time in 3 months

pull request commentHakuyume/socketcan-rs

Support musl

Yep, that should fix it. Did it myself in a local branch ;)

Hakuyume

comment created time in 3 months

issue openedHakuyume/socketcan-rs

Mismatch types on arm device

error[E0308]: mismatched types
   --> /home/op/.cargo/registry/src/github.com-1ecc6299db9ec823/socketcan-alt-0.2.2/src/socket.rs:124:50
    |
124 |             (*msg.as_mut_ptr()).msg_controllen = cmsg_buf.len();
    |                                                  ^^^^^^^^^^^^^^ expected `u32`, found `usize`
    |
help: you can convert an `usize` to `u32` and panic if the converted value wouldn't fit
    |
124 |             (*msg.as_mut_ptr()).msg_controllen = cmsg_buf.len().try_into().unwrap();
    |                                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

This happened on armv7-unknown-linux-musleabihf

created time in 3 months

startedHakuyume/socketcan-rs

started time in 3 months

issue commentrust-lang/rust-clippy

eval_order_dependence shouldn't fire for struct initializers

I tried a few things yesterday, but they either broke existing tests (not sure if legitmate) oder hadn't the desirede effect. I don't think that this should be too hard 😅 But yeah, a look would be great @flip1995

CAD97

comment created time in 3 months

issue commentrust-lang/rust

False positive on dead_code lint

searched nightlies: from nightly-2020-01-26 to nightly-2020-08-03 regressed nightly: nightly-2020-05-03 searched commits: from https://github.com/rust-lang/rust/commit/7f65393b9abf5e70d0b9a8080558f17c5625bd40 to https://github.com/rust-lang/rust/commit/f05a5240440b3eaef1684a7965860fab40301947 regressed commit: https://github.com/rust-lang/rust/commit/dae90c195989b09475b6c0225a3018cbd7afa587

<details> <summary>bisected with <a href='https://github.com/rust-lang/cargo-bisect-rustc'>cargo-bisect-rustc</a> v0.5.2</summary>

Host triple: x86_64-unknown-linux-gnu Reproduce with:

cargo bisect-rustc --access github --regress success 

</details>


How is that related? 😅 But nevertheless: @rustbot modify labels: E-needs-test

martinthomson

comment created time in 3 months

issue commentrust-lang/rust-clippy

eval_order_dependence shouldn't fire for struct initializers

It hit me today. Here's a simplified version:

async fn one() -> u32 { 1 }
async fn two() -> u32 { 2 }

pub struct TwoInts {
    a: u32,
    b: u32,
}

pub async fn ff() -> TwoInts {
    TwoInts {
        a: one().await,
        b: two().await,
    }
}

gives

warning: unsequenced read of a variable
  --> src/lib.rs:12:12
   |
12 |         b: two().await,
   |            ^^^^^^^^^^^
   |
   = note: `#[warn(clippy::eval_order_dependence)]` on by default
note: whether read occurs before this write depends on evaluation order
  --> src/lib.rs:11:12
   |
11 |         a: one().await,
   |            ^^^^^^^^^^^
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#eval_order_dependence

warning: unsequenced read of a variable
  --> src/lib.rs:11:12
   |
11 |         a: one().await,
   |            ^^^^^^^^^^^
   |
note: whether read occurs before this write depends on evaluation order
  --> src/lib.rs:12:12
   |
12 |         b: two().await,
   |            ^^^^^^^^^^^
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#eval_order_dependence

IMHO this is safe and should not be linted.

@flip1995 Could you add the correct labels as well as maybe give an instruction on how to fix this? I would work on this, but currently have no plan to start where :)

CAD97

comment created time in 3 months

more