profile
viewpoint

aloucks/dacite 1

Mirror of https://gitlab.com/dennis-hamester/dacite

aloucks/directx_math 1

DirectXMath for Rust

aloucks/ash 0

Vulkan bindings for Rust

aloucks/atom-build-cargo 0

Cargo task runner plugin for atom-build

aloucks/backtrace-rs 0

Backtraces in Rust

aloucks/borderless-window 0

A minimal borderless window with the Windows API

aloucks/bucket 0

AWS Bucket Synchronization Tool

aloucks/cargo 0

The Rust package manager

aloucks/cgmath 0

A linear algebra and mathematics library for computer graphics.

push eventaloucks/spng-rs

Aaron Loucks

commit sha 6efa80128ffc79b1a53818078970bd602f614a9a

Update libspng

view details

push time in a day

issue commentrust-lang/rustfmt

Newline style changes to Unix-style when file is modified

The content returned by snippet_provider.entire_snippet() is used to check if CRLF exists when using Auto. It looks like, at least on master, that input now normalized to only contain \n prior to the check . As far as I can tell, this is happening when the SourceMap loads the file and eventually calls SourceFile::new.

https://github.com/rust-lang/rustfmt/blob/494452b142fd54800d215cecc971302b3e885b7b/src/formatting.rs#L190-L194

ajtribick

comment created time in a day

issue commentrust-lang/rustfmt

Newline style changes to Unix-style when file is modified

How long has this been an issue? I recall there was a change to newline handling a while back that broke a bunch of CI, but I thought that was fixed. I can see in the history that there were a lot of changes about a year ago:

https://github.com/rust-lang/rustfmt/commits/master/src/formatting/newline_style.rs

ajtribick

comment created time in a day

pull request commentrust-analyzer/rust-analyzer

Unsquish parameter types in tooltips for macro-generated functions

This is a band-aid fix for one small use case. &mut types, for example, are still squashed. I had hoped that the ra_fmt crate might have some utilities to format code blocks, but it's rather minimal at the moment. Is the long term goal to implement a formatter, re-use rustfmt, or TBD?

aloucks

comment created time in a day

PR opened rust-analyzer/rust-analyzer

Unsquish parameter types in tooltips for macro-generated functions

Note the missing whitespace between : and the parameter type.

Before: image

After: image

+12 -1

0 comment

1 changed file

pr created time in a day

create barnchaloucks/rust-analyzer

branch : unsquish_param_types

created branch time in a day

pull request commentrust-analyzer/rust-analyzer

Enable hover and autocomplete docs on macro generated items

Tests have been added. This should be ready for review now.

aloucks

comment created time in 2 days

pull request commentrust-analyzer/rust-analyzer

Introduce hover actions

BTW, having command links in markdown has one benefit: vscode supports command links from 2017 (microsoft/vscode#29082) and there is a good chance that other editors support them too (I didn't check).

Ah cool! I wasn't aware of that.

I wonder if this could be use to transform intra-doc links into go-to-def links?

vsrs

comment created time in 2 days

issue commentalexcrichton/cmake-rs

gracefully handling of CC/CXX change

Do you mean you're running cmake out of band (i.e. by hand)?

The build.rs script might not even be invoked again. Have you tried emitting rerun-if?

Dushistov

comment created time in 2 days

issue commentrustgd/cgmath

Migrate to packed_simd

There are a couple other math libraries with SIMD support:

https://github.com/termhn/ultraviolet Ultraviolet's claim-to-fame is using "Structure of Arrays" (SoA) to gain a performance edge, but it may complicate your architecture (note the SoA types aren't mandatory). Ultraviolet seems quite experimental and lightly maintained. It uses rotors instead quaternions for rotation.

https://github.com/bitshifter/glam-rs Glam seems to be a bit more popular and I believe it to be a solid choice. I think it's inspired by DirectXMath, but with a smaller API surface area.

https://github.com/aloucks/directx_math I've also recently translated most of DirectXMath into a new crate. It's pure rust (i.e. not ffi bindings), but the API is as close to 1:1 with the c++ API as possible. This makes it feel a bit alien to use directly. I'm working on a wrapper crate to make it feel like idiomatic rust, but it's not published yet.

NNemec

comment created time in 2 days

push eventaloucks/rust-analyzer

Aaron Loucks

commit sha 1e5044cfa664dec3ad8856e3629e7a95a1803ba3

Add basic hover and completion doc tests for macro generated items

view details

push time in 2 days

pull request commentrust-analyzer/rust-analyzer

Introduce hover actions

For inlay hints yes, it does. It makes possible to choose a type to go to.

These look really nice and definitely useful!

However, I think I prefer the way the code lens was displayed before (outside of tooltip) for running tests and finding implementations.

vsrs

comment created time in 3 days

pull request commentrust-analyzer/rust-analyzer

Introduce hover actions

Does this add new functionality or just move the code lens into the tooltip?

vsrs

comment created time in 3 days

PR opened rust-analyzer/rust-analyzer

Enable hover and autocomplete docs on macro generated items

Enable hover and autocomplete docs on macro generated items. This de-sugars doc comments into doc attributes in some cases, but not all. Comments and doc attributes are then merged together.

This PR is essentially a partial implementation of what's being suggested #3182, but it's not all the way there yet. I still need to add unit tests, but I wanted to first get feedback on whether or not this was an acceptable path forward.

Fixes #4564 Fixes #3984 Fixes #3180 Related #3182

macro_item_docs

+110 -10

0 comment

5 changed files

pr created time in 3 days

create barnchaloucks/rust-analyzer

branch : macro_item_doc_comments

created branch time in 3 days

issue commentrust-analyzer/rust-analyzer

Incoherent syntax highlighting in VS Code

You can disable semantic highlighting per-theme in your settings.json.

    "editor.semanticTokenColorCustomizations": {
        "[Monokai]": {
            "enabled": false,
        }
    },
Moxinilian

comment created time in 3 days

issue closedrust-lang/rls

RLS should have finer grained build options in addition to `all_targets`

It would be nice if we could have finer grained build options instead of only all_targets. There are often times when I'd like to build all binaries or examples, but not the tests. It looks like cargo has support for this:

$ cargo check --help | rg "Check all"
        --all                       Check all packages in the workspace
        --bins                      Check all binaries
        --examples                  Check all examples
        --tests                     Check all tests
        --benches                   Check all benches
        --all-targets               Check all targets

We should add these options:

  • all_packages
  • all_binaries
  • all_examples

closed time in 3 days

aloucks

issue closedalex/rust-asn1

Publish to crates.io?

The README shows 0.3 but the latest version on crates.io is 0.1 and it's over four years old.

https://crates.io/crates/asn1

closed time in 3 days

aloucks

push eventaloucks/spng-rs

Aaron Loucks

commit sha 5bb59f738a1465a447d7d0640f6252deab5104c2

Version 0.1.0-alpha.4

view details

push time in 3 days

created tagaloucks/spng-rs

tagv0.1.0-alpha.4

Rust bindings to libspng

created time in 3 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha c084f8babaeed9f97c2af110c9d07e1a35925ff3

Update libspng and README

view details

push time in 3 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha 880bfebb99cf0c1e1c91976d785e16abe34460d9

Update libspng and README

view details

push time in 3 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha 54436f0e8c6616f3f33ebb4b490c7fdf0d1c3f4c

Add benchmmarks - Enable SPNG_SSE=4 with target_feature = sse4.1 - Add RGB and RGBA ColorType aliases - Remove Decoder<&[u8]>::read_info_from_slice, as the benchmarks showed it had no real performance benefits

view details

push time in 3 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha 08dc86ef0f1cd3a192faaeee8715b7ca79585ed2

Fix clippy warnings

view details

push time in 4 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha 42c6d59fb70a2ea17e748c36dfce4f373f093c0d

Refactoring RawContext

view details

Aaron Loucks

commit sha ed99b0d7c429451946041f01cd9a60d05c381b42

Add addtional RawContext methods

view details

Aaron Loucks

commit sha f0300becc0d40993d04978e3fc1e5644f3836d29

Update docs

view details

Aaron Loucks

commit sha a4e1c15b2ea538db4d679bc08160ce0016046020

Add one-liner for simple decoding and more refactoring

view details

push time in 4 days

issue closeddpc/mioco.pre-0.9

"socket already registered" error when running echo example

mioco v0.4.1

$ rustc --version --verbose
rustc 1.9.0-nightly (c8b8eb1fd 2016-04-01)
binary: rustc
commit-hash: c8b8eb1fda90998832ba1cdf96a34dc676f7124b
commit-date: 2016-04-01
host: x86_64-pc-windows-gnu
release: 1.9.0-nightly

$ RUST_BACKTRACE=1 target/debug/echo.exe
Starting tcp echo server on V4(127.0.0.1:5555)
thread '<main>' panicked at 'register failed: Error { repr: Custom(Custom { kind: Other, error: StringError("socket already registered") }) }', ../src/libcore\result.rs:746
stack backtrace:
   0:           0x9442ba - std::panicking::default_hook::_$u7b$$u7b$closure$u7d$$u7d$::hff309ab1d83ffd90
   1:           0x9437d4 - std::panicking::default_hook::h08ad3bb09872855b
   2:           0x90615f - std::sys_common::unwind::begin_unwind_inner::hfa66df7b3e69707e
   3:           0x907ceb - std::sys_common::unwind::begin_unwind_fmt::h1952eb42d4b32c9d
   4:           0x93695b - rust_begin_unwind
   5:           0x958a15 - core::panicking::panic_fmt::ha6b3c19493c123b3
   6:           0x41abc9 - core::result::unwrap_failed::h8ef88a17914f2dff
                        at ../src/libcore/macros.rs:29
   7:           0x442f5b - _<std..result..Result<T, E>>::expect::hdaf276e0c425b331
                        at ../src/libcore/result.rs:708
   8:           0x442ec7 - _<T as mioco..evented..EventSourceTrait>::register::h269a86b0f007dda3
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/evented.rs:262
   9:           0x442dd2 - _<mioco..evented..RcEventSource<T> as mioco..evented..RcEventSourceTrait>::register::h4ae57510b9c26ea1
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/evented.rs:388
  10:           0x46ec97 - mioco::coroutine::Coroutine::register_all::h7e25f1d5fc32837f
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/coroutine.rs:406
  11:           0x46e559 - mioco::CoroutineControl::after_resume::h4aab2d217b84a89d
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/lib.rs:511
  12:           0x46c159 - mioco::CoroutineControl::resume::ha747a58c37adf5c6
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/lib.rs:505
  13:           0x46bc3b - _<FifoSchedulerThread as SchedulerThread>::ready::h3f9a8ad5eb884d26
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/lib.rs:448
  14:           0x49312d - _<thread..Handler as mio_orig..Handler>::ready::h16ec6e1e5b15a4a9
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/thread.rs:344
  15:           0x431229 - _<mioco..mio..EventLoop<H>>::io_event::h76def7321b8d98bb
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mio-0.5.0\src/event_loop.rs:343
  16:           0x431134 - _<mioco..mio..EventLoop<H>>::io_process::h896936efd5d72243
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mio-0.5.0\src/event_loop.rs:335
  17:           0x430288 - _<mioco..mio..EventLoop<H>>::run_once::h0bd7da29d417e7a9
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mio-0.5.0\src/event_loop.rs:298
  18:           0x42fb65 - _<mioco..mio..EventLoop<H>>::run::h5c3fadb94424b876
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mio-0.5.0\src/event_loop.rs:247
  19:           0x42495b - mioco::Mioco::thread_loop::hafedcaac4b4d5f54
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/lib.rs:726
  20:           0x417a34 - mioco::Mioco::run::hafc7a40413bb3a3f
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/lib.rs:680
  21:           0x401f02 - mioco::Mioco::start::hc604b9914e1d3f9c
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/lib.rs:625
  22:           0x401e17 - mioco::start::h73952a8455bf6e85
                        at G:\Users\Aaron\.cargo\registry\src\github.com-88ac128001ac3a9a\mioco-0.4.1\src/lib.rs:837
  23:           0x401840 - echo::main::hc184f21f24de94da
                        at src\bin/echo.rs:18
  24:           0x942e4d - std::sys_common::unwind::try::h6809d57ce7e089a3
  25:           0x942c7a - std::rt::lang_start::h12d9b3310b48a726
  26:           0x45c9ba - main
  27:           0x4013b4 - _tmainCRTStartup
  28:           0x4014e7 - mainCRTStartup
  29:         0x772259ec - strncmp

closed time in 5 days

aloucks

issue closedintellij-rust/intellij-rust

Auto-complete does not work with `bitflags!` generated structs

<!-- Hello and thank you for the issue! If you would like to report a bug, we have added some points below that you can fill out. Feel free to remove all the irrelevant text to request a new feature. -->

Environment

  • Intellij-Rust plugin version: Rust (0.2.95.2120-191)
  • Rust toolchain version: rustc 1.33.0 (2aa4c46cf 2019-02-28)
  • IDE name and version: IntelliJ IDEA 2019.1 Build #IC-191.6183.87 March 27, 2019
  • Operating system: Windows 10 Pro 64bit

Problem description

Auto-completion does not work for the associated constants of structs created with bitflags!.

In addition, Goto Declaration fails when structs are imported with Rust 2018 edition syntax:

use bitflags::bitflags;

Using Rust 2015 edition syntax enables Goto Declaration to work, but the auto-completion still does not.

#[macro_use]
extern crate bitflags;

Steps to reproduce

Cargo.toml

[package]
name = "foo"
version = "0.1.0"
edition = "2018"

[dependencies]
bitflags = "1.0.4"

main.rs (2018 edition syntax)

use bitflags::bitflags;

bitflags! {
    struct Foo: u32 {
        const A = 0b00000000;
        const B = 0b10000000;
    }
}

fn main() {
    Fo<auto-complete-here-does-NOT-find-the-struct>
    Foo::<auto-complete-here-does-NOT-find-A-or-B>
}

main.rs (2015 edition syntax)

#[macro_use]
extern crate bitflags;

bitflags! {
    struct Foo: u32 {
        const A = 0b00000000;
        const B = 0b10000000;
    }
}

fn main() {
    Fo<auto-complete-finds-the-struct>
    Foo::<auto-complete-here-does-NOT-find-A-or-B>
}

It's understandable that general support for macro generated structs may be a long way off (or impossible?), but it would be nice if support for bitflags! could be baked in, considering it's the 3rd most downloaded crate on crates.io.

closed time in 5 days

aloucks

issue commentrust-lang/crates.io

README is often not rendered on crates.io when using Chrome

I only see it happen in chrome though, which is what's so strange.

aloucks

comment created time in 5 days

issue commentrust-lang/crates.io

README is often not rendered on crates.io when using Chrome

I can still reproduce it.

When it happens, I see the request as either "pending" or as "failed" in the network tab.

If I click the request and go to the "Timing" tab, it shows the following:

image

This is the link in the "Explanation":

https://developers.google.com/web/tools/chrome-devtools/network/reference#timing-explanation

Timing breakdown phases explained Here's more information about each of the phases you may see in the Timing tab:

  • Queueing. The browser queues requests when:
    • There are higher priority requests.
    • There are already six TCP connections open for this origin, which is the limit. Applies to HTTP/1.0 : > and HTTP/1.1 only.
    • The browser is briefly allocating space in the disk cache
  • Stalled. The request could be stalled for any of the reasons described in Queueing.

Although it seems to show "pending" more often than "failed", when it does show failed, there's a little more info in the response headers:

Request URL: https://static.crates.io/readmes/tokio/tokio-0.2.21.html
Referrer Policy: no-referrer-when-downgrade
cache-control: public,max-age=604800
content-encoding: gzip
content-type: text/html
date: Thu, 28 May 2020 00:14:34 GMT
last-modified: Wed, 13 May 2020 19:02:31 GMT
server: AmazonS3
status: 200
vary: Accept-Encoding
via: 1.1 22e9d361a9c4153886c1c8aa0eb4ffa8.cloudfront.net (CloudFront)
x-amz-cf-id: u6mzWD9Jhl1ylcCLig3HrkA9ifSNJLcFTYm4kImhb-mpGJGJxsdxPw==
x-amz-cf-pop: IAD89-C3
x-amz-version-id: qqYxHeLvwS5rzF075.PP0jcCSEux5ozF
x-cache: Miss from cloudfront

Provisional headers are shown
DNT: 1
Referer: https://crates.io/crates/tokio
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36

image

When I refresh until it works, I noticed that the x-cache header now indicates a cache hit. No idea if it's related, but it seems odd:

image

aloucks

comment created time in 5 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha 9bbf1cdffb00ab02b26bb6d9bbb784c7ab65248a

Move RawContext into raw mod

view details

push time in 5 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha efab8695f9298b9f68bae45d8d4f9af784f3617d

Use MaybeUninit when fetching chunk data

view details

Aaron Loucks

commit sha b6a4185fb7f1103f93b0c3464725f8e99d689f7f

Move RawContext into raw mod

view details

push time in 5 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha 2b43dddb90da0bc4aa033fa14d191e8f1bfceed2

Update libspng to master and expose RawContext for now

view details

push time in 6 days

issue closedrandy408/libspng

The _mm_abs_epi16 SPNG_SSE check appears to enable SSSE3 instructions in SSE3 context

_mm_abs_epi16 is SSSE3.

And, it looks like you're setting SPNG_SSE = 3 for SSSE3:

https://github.com/randy408/libspng/blob/954b5570a02822a1fdd3c7508ac86ce5984aedee/spng.c#L3843-L3845

As far as I can tell, the SPNG_SSE values correspond to:

SPNG_SSE == 1 = SSE + SSE2 SPNG_SSE == 2 = SSE3 SPNG_SSE == 3 = SSSE3 SPNG_SSE == 4 = SSE4.1 + SSE4.2

Should this guard be set to #if SPNG_SSE >= 3 ?

https://github.com/randy408/libspng/blob/954b5570a02822a1fdd3c7508ac86ce5984aedee/spng.c#L4022-L4024

closed time in 6 days

aloucks

issue closedrandy408/libspng

Build fails in Windows/MSVC

Building on windows worked as of commit: https://github.com/randy408/libspng/tree/2079ef6f223feea2570b537c047c9140a5b72551

However, it now fails on master/0.6-RC1

commit 466a080234e3b64fbacb1edae0e0ab97edd6aad7:

It looks like pointer arithmetic on void* isn't standard.

$ cmake --build . 
Microsoft (R) Build Engine version 16.5.0+d4cbfca49 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.

  spng.c
D:\projects\libspng\spng.c(647,19): error C2036: 'void *': unknown size [D:\projects\libspng\build\
spng.vcxproj]
D:\projects\libspng\spng.c(713,37): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(722,29): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(743,41): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(744,46): error C2036: 'void *': unknown size [D:\projects\libspng\build\ 
spng.vcxproj]
D:\projects\libspng\spng.c(823,33): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(2105,40): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng.vcxproj]
D:\projects\libspng\spng.c(2105,43): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng.vcxproj]
D:\projects\libspng\spng.c(2693,20): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng.vcxproj]
D:\projects\libspng\spng.c(2775,34): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng.vcxproj]
D:\projects\libspng\spng.c(2832,23): warning C4018: '<=': signed/unsigned mismatch [D:\projects\lib 
spng\build\spng.vcxproj]
D:\projects\libspng\spng.c(3060,37): warning C4267: '=': conversion from 'size_t' to 'uint32_t', po 
ssible loss of data [D:\projects\libspng\build\spng.vcxproj]
  spng.c
D:\projects\libspng\spng.c(647,19): error C2036: 'void *': unknown size [D:\projects\libspng\build\
spng_static.vcxproj]
D:\projects\libspng\spng.c(713,37): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(722,29): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(743,41): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(744,46): error C2036: 'void *': unknown size [D:\projects\libspng\build\ 
spng_static.vcxproj]
D:\projects\libspng\spng.c(823,33): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(2105,40): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng_static.vcxproj]
D:\projects\libspng\spng.c(2105,43): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng_static.vcxproj]
D:\projects\libspng\spng.c(2693,20): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(2775,34): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(2832,23): warning C4018: '<=': signed/unsigned mismatch [D:\projects\lib 
spng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(3060,37): warning C4267: '=': conversion from 'size_t' to 'uint32_t', po 
ssible loss of data [D:\projects\libspng\build\spng_static.vcxproj]

closed time in 6 days

aloucks

issue commentrandy408/libspng

Build fails in Windows/MSVC

Thanks!

aloucks

comment created time in 6 days

push eventaloucks/spng-rs

Aaron Loucks

commit sha 35bc74fe9bafd4dfc7cb2bb80b96fff0842c641d

Update libspng to master and expose RawContext for now

view details

push time in 6 days

issue openedrandy408/libspng

The _mm_abs_epi16 SPNG_SSE check appears to enable SSSE3 instructions in SSE3 context

_mm_abs_epi16 is SSSE3.

And, it looks like you're setting SPNG_SSE = 3 for SSSE3:

https://github.com/randy408/libspng/blob/954b5570a02822a1fdd3c7508ac86ce5984aedee/spng.c#L3843-L3845

As far as I can tell, the SPNG_SSE values correspond to:

SPNG_SSE == 1 = SSE + SSE2 SPNG_SSE == 2 = SSE3 SPNG_SSE == 3 = SSSE3 SPNG_SSE == 4 = SSE4.1 + SSE4.2

Should this guard be set to #if SPNG_SSE >= 3 ?

https://github.com/randy408/libspng/blob/954b5570a02822a1fdd3c7508ac86ce5984aedee/spng.c#L4022-L4024

created time in 6 days

pull request commentgfx-rs/wgpu

[0.5] Various correctness fixes

@kvark

Latest https://crates.io/crates/wgpu/0.5.0 was published from the corresponding v0.5 branch here

Ah, Ok! I had not seen that branch. I was looking at master and saw that the changes weren't reflected in the crates.io code. Thanks for clearing that up.

kvark

comment created time in 6 days

pull request commentgfx-rs/wgpu

[0.5] Various correctness fixes

@kvark It's confusing that this repository doesn't actually represent the source code that's published to crates.io. It seems like things are being cherry-picked into some other repo and then published from there. I know that there is some sync setup with a mozilla repository but I assumed that it was a 1:1 mirror of this one. Is that not the case?

What repository represents the system of record for these crates? Do they have tags?

kvark

comment created time in 6 days

issue openedintellij-rust/intellij-rust

Tooltips are missing docs on macro generated functions

Environment

  • IntelliJ Rust plugin version: 0.2.122.3105-201
  • Rust toolchain version: 1.43.1 (8d69840ab 2020-05-04) x86_64-pc-windows-msvc
  • IDE name and version: IntelliJ IDEA 2020.1.1 Community Edition (IC-201.7223.91)
  • Operating system: Windows 10 10.0

Problem description

Documentation on functions generated via macros is not available in tooltips or autocomplete.

Steps to reproduce

pub struct Bar {
    pub bar: i32
}

macro_rules! foobar {
    ($Name:ident) => {
        impl $Name {
            /// Say hello
            pub fn hello(&self) {
                println!("hello: {}", self.bar)
            }
        }
    }
}

foobar!(Bar);

pub fn say_hello() {
    let foo = Bar { bar: 1 };
    foo.hello();
}

I would expect to see "Say hello" in the tooltip.

image

image

created time in 6 days

created tagaloucks/directx_math

tagv0.1.0

DirectXMath for Rust

created time in 6 days

push eventaloucks/directx_math

Aaron Loucks

commit sha dbda76104f7c10ff11b981c6cfdcb86b8056c3f6

Update readme

view details

Aaron Loucks

commit sha 1fb9ca4f422bbdca5ab6ba751bdd9f6a369bb47e

Version v0.1.0

view details

push time in 6 days

push eventaloucks/directx_math

Aaron Loucks

commit sha b3dac433987f0e40519e910a3ecba5f89cbde9e3

Update description and categories

view details

push time in 6 days

push eventaloucks/directx_math

Aaron Loucks

commit sha d88a6b8a65edc8cad9c2538f794d557709fded14

Fix XMStoreFloat3 to accept Align16<XMFLOAT3>

view details

Aaron Loucks

commit sha 569d1ed0223a9b0a75c52f8ecbefdcb07fa89e56

Update docs

view details

push time in 6 days

issue openedrandy408/libspng

Build fails in Windows/MSVC

Building on windows worked as of commit: https://github.com/randy408/libspng/tree/2079ef6f223feea2570b537c047c9140a5b72551

However, it now fails on master/0.6-RC1

commit 466a080234e3b64fbacb1edae0e0ab97edd6aad7:

$ cmake --build . 
Microsoft (R) Build Engine version 16.5.0+d4cbfca49 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.

  spng.c
D:\projects\libspng\spng.c(647,19): error C2036: 'void *': unknown size [D:\projects\libspng\build\
spng.vcxproj]
D:\projects\libspng\spng.c(713,37): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(722,29): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(743,41): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(744,46): error C2036: 'void *': unknown size [D:\projects\libspng\build\ 
spng.vcxproj]
D:\projects\libspng\spng.c(823,33): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng.vcxproj]
D:\projects\libspng\spng.c(2105,40): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng.vcxproj]
D:\projects\libspng\spng.c(2105,43): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng.vcxproj]
D:\projects\libspng\spng.c(2693,20): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng.vcxproj]
D:\projects\libspng\spng.c(2775,34): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng.vcxproj]
D:\projects\libspng\spng.c(2832,23): warning C4018: '<=': signed/unsigned mismatch [D:\projects\lib 
spng\build\spng.vcxproj]
D:\projects\libspng\spng.c(3060,37): warning C4267: '=': conversion from 'size_t' to 'uint32_t', po 
ssible loss of data [D:\projects\libspng\build\spng.vcxproj]
  spng.c
D:\projects\libspng\spng.c(647,19): error C2036: 'void *': unknown size [D:\projects\libspng\build\
spng_static.vcxproj]
D:\projects\libspng\spng.c(713,37): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(722,29): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(743,41): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(744,46): error C2036: 'void *': unknown size [D:\projects\libspng\build\ 
spng_static.vcxproj]
D:\projects\libspng\spng.c(823,33): warning C4267: '=': conversion from 'size_t' to 'uInt', possibl 
e loss of data [D:\projects\libspng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(2105,40): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng_static.vcxproj]
D:\projects\libspng\spng.c(2105,43): error C2036: 'void *': unknown size [D:\projects\libspng\build 
\spng_static.vcxproj]
D:\projects\libspng\spng.c(2693,20): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(2775,34): warning C4018: '<': signed/unsigned mismatch [D:\projects\libs 
png\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(2832,23): warning C4018: '<=': signed/unsigned mismatch [D:\projects\lib 
spng\build\spng_static.vcxproj]
D:\projects\libspng\spng.c(3060,37): warning C4267: '=': conversion from 'size_t' to 'uint32_t', po 
ssible loss of data [D:\projects\libspng\build\spng_static.vcxproj]

created time in 7 days

issue commentgpuweb/gpuweb

vec4<f32> is too hard to type on the keyboard

ubyte4 ->  vec4<u8>
ushort4 -> vec4<u16>
uint4 ->   vec4<u32>
float4 ->  vec4<f32>

I find the items on the right easier to both read and to type. I guess it's subjective.

The prefix is also always the same which has a benefit of everything lining up and looks much more consistent.

litherum

comment created time in 7 days

issue openedrust-lang/rfcs

Use github issue templates to minimize erroneous RFC proposals

There are quite a few submitted RFCs that do not follow the guidelines or use the template in this repo. Perhaps a github issue template may be used to pre-fill the issue with all the relevant information, instructions, and a pre-RFC checklist and may help minimize these "fly-by" RFCs.

https://help.github.com/en/github/building-a-strong-community/configuring-issue-templates-for-your-repository

created time in 7 days

PR opened rust-analyzer/rust-analyzer

Hover tooltip module name is monospace once again

The line separator is also moved below the function signature to split regions between the docs. This is very similar to how IntelliJ displays tooltips. Adding an additional separator between the module name and function signature currently has rendering issues.

Fixes #4594 Alternative to #4615

@kjeremy @Veetaha

Note that I have semantic coloring disabled so ignore any differences due to that.

image

image

+12 -9

0 comment

3 changed files

pr created time in 7 days

create barnchaloucks/rust-analyzer

branch : issue-4594_module_monospaced

created branch time in 7 days

pull request commentrust-analyzer/rust-analyzer

Use multiple marked strings for hover content

The "---" or "___" trick doesn't work well when there is a code block below it. It doesn't set the vertical spacing correctly and the regions are jammed together. The only way to have the spacing look right is with the multiple marked strings, as far as I can tell.

In any case, after messing around with this, I definitely don't think there should be a double newline between the sections even if the line separator doesn't work out in the near term. The double newline looked really weird in most cases.

If this PR isn't satisfactory, can we revert the original one that caused the issue? The non-monospaced module path is quite unsightly.

aloucks

comment created time in 7 days

pull request commentrust-analyzer/rust-analyzer

Use multiple marked strings for hover content

https://github.com/microsoft/language-server-protocol/issues/518

aloucks

comment created time in 7 days

pull request commentrust-analyzer/rust-analyzer

Use multiple marked strings for hover content

@Veetaha @kjeremy I think this resolves the issues with the hover tooltip. The migration to multiple marked strings also allows greater flexibility for adding additional content without messing around with string concatenation. VSCode automatically renders a thin line between the content sections, adding a natural separation.

aloucks

comment created time in 8 days

push eventaloucks/rust-analyzer

Aaron Loucks

commit sha 683a249ea8ad890c388249c6576b8e556387b8f5

Fixed proc_macro_resolve test Also removed redundant clone in HoverResult.

view details

push time in 8 days

push eventaloucks/rust-analyzer

Aaron Loucks

commit sha 2892487b0d796b36078f0f83db33e3126607e4d6

Fixed proc_macro_resolve test Also removed redundant clone in HoverResult.

view details

push time in 8 days

PR opened rust-analyzer/rust-analyzer

Use multiple marked strings for hover content

Also moved them module name below function signatures.

Fixes #4594 Fixes #3813

cc #3813 cc #4559

image

image

image

image

+83 -90

0 comment

5 changed files

pr created time in 8 days

create barnchaloucks/rust-analyzer

branch : issue-4594_hover_marked_strings

created branch time in 8 days

issue commentrust-analyzer/rust-analyzer

Module path in on-hover message is no-longer monospace

I've got a fix for this in the works that migrates to using multiple marked strings. Just sorting out the unit tests now.

Veetaha

comment created time in 8 days

pull request commentrust-analyzer/rust-analyzer

Module name on hover shows another newline after it

The change here cause rendering issues. The font for the module is incorrect and the rendered line overlaps the text below it.

The problem is that there needs to be multiple marked strings returned, but the change here injects "___" as a line separator instead and continues to use a single marked string.

When using multiple marked strings, you'll get the line separator automatically.

For reference, this is how it's done in RLS: https://github.com/rust-lang/rls/blob/fe46c95c3f01fbdaca36bdf70739d32062c1f53a/rls/src/actions/hover.rs#L482

Arthamys

comment created time in 8 days

issue commentrust-analyzer/rust-analyzer

Module name on hover should have another newline after it

The merged change (#4559) has some negative side effects. The module name is no longer in the correct font (it's not rendering with the code font, i.e. it's not monospace any longer). The line separator is also overlapping the text below it.

kjeremy

comment created time in 8 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 777c492ba01efecb114254491f19c7e7af2e948a

Documentation update

view details

push time in 8 days

pull request commentGekkio/imgui-rs

Make cmd_lists_count public in DrawData struct

This should probably be a getter method instead. Making it public allows the value to be mutated which makes draw_lists() unsafe:

    pub fn draw_lists(&self) -> DrawListIterator {
        unsafe {
            DrawListIterator {
                iter: self.cmd_lists().iter(),
            }
        }
    }
    pub(crate) unsafe fn cmd_lists(&self) -> &[*const DrawList] {
        slice::from_raw_parts(
            self.cmd_lists as *const *const DrawList,
            self.cmd_lists_count as usize,
        )
    }
filnet

comment created time in 9 days

created tagaloucks/directx_math

tagv0.1.0-alpha.6

DirectXMath for Rust

created time in 10 days

push eventaloucks/directx_math

Aaron Loucks

commit sha ec18a74814d85ee5425d5dcbfca8589f92cd488e

Version v0.1.0-alpha.6

view details

push time in 10 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 8e43ac3f06c752fc5d91c216b8fbc74dcd10152a

CreateFromPoints for BoundingVolume types to now accepts an Iterator Although `IntoIterator` is nice for accepting slices of `XMFLOAT3`, the `Clone` requirement makes it difficult or impossible to use in combination with `map`.

view details

push time in 11 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 6b94832e9588cfec8649155493c137c6981edeaa

Add missing collision GetCorners functions and update docs

view details

push time in 11 days

issue commentgfx-rs/wgpu-rs

Buffer ranges

Related https://github.com/gfx-rs/wgpu/issues/654

kvark

comment created time in 11 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 84eb81f290172bf0fcb6964a2947ce79a547b06c

Update docs

view details

push time in 11 days

issue commentrust-analyzer/rust-analyzer

Module name on hover should have another newline after it

The RLS vscode extension renders a thin line between the hover tooltip sections (or at least it did; I haven't used it in a long time). I think that would be preferable over empty lines.

kjeremy

comment created time in 11 days

issue openedrust-analyzer/rust-analyzer

Docs on macro generated functions do not show up in hover tooltips or autocomplete

pub struct Foo;

macro_rules! foo {
    ($Name:ident) => {
        impl $Name {
            /// Prints `bar`
            pub fn bar(&self) {
                println!("bar")
            }
        }
    };
}

foo!(Foo);

fn baz() {
    let foo = Foo;
    foo.bar(); // <-- hover over "bar"
}

Rustdoc will generate the docs, but rust-analyzer seems to ignore them when inside of a macro.

created time in 11 days

push eventaloucks/directx_math

Aaron Loucks

commit sha d44cc7784f1a0e1ed49e85320d4d2072d069ba9b

Add #[must_use] to uninitialized

view details

push time in 12 days

issue closedrust-analyzer/rust-analyzer

Code lens test button does not pass the correct filter string to `cargo test`

The name of the trait or struct is omitted from the filter string.

pub mod quax {
    pub struct Foo;

    pub trait Bar {
        fn bar(&self);

        /// Bar
        /// ```
        /// # use my_crate::quax::{Foo, Bar};
        ///
        /// let foo = Foo;
        /// foo.baz();
        /// ```
        fn baz(&self) {
            self.bar();
        }
    }

    impl Bar for Foo {
        
        fn bar(&self) {
            println!("bar");
        }
    }
}

What happens when pressing the "Play" button for on the doctest:

Filter: quax::baz

Executing task: cargo test --doc --package my_crate -- quax::baz --nocapture
...
running 0 tests.
...

What I would expect to happen when pressing the "Play" button:

Filter: quax::Bar::baz

Executing task: cargo test --doc --package my_crate -- quax::Bar::baz --nocapture
...
running 1 test
test src\lib.rs - quax::Bar::baz (line 1246) ... ok
...

closed time in 12 days

aloucks

issue commentrust-analyzer/rust-analyzer

Code lens test button does not pass the correct filter string to `cargo test`

Confirmed that it's fixed in today's nightly. 👍

aloucks

comment created time in 12 days

push eventaloucks/directx_math

Aaron Loucks

commit sha fb2a07c17ff54dd763d0e0e3a1fb4bab0938453e

Update docs Note that the XMVectorBaryCentric docs appear to be mangled at the source.

view details

push time in 13 days

issue openedrust-analyzer/rust-analyzer

Code lens test button does not pass the correct filter string to `cargo test`

The name of the trait or struct is omitted from the filter string.

pub mod quax {
    pub struct Foo;

    pub trait Bar {
        fn bar(&self);

        /// Bar
        /// ```
        /// # use my_crate::quax::{Foo, Bar};
        ///
        /// let foo = Foo;
        /// foo.baz();
        /// ```
        fn baz(&self) {
            self.bar();
        }
    }

    impl Bar for Foo {
        
        fn bar(&self) {
            println!("bar");
        }
    }
}

What happens when pressing the "Play" button for on the doctest:

Filter: quax::baz

Executing task: cargo test --doc --package my_crate -- quax::baz --nocapture
...
running 0 tests.
...

What I would expect to happen when pressing the "Play" button:

Filter: quax::Bar::baz

Executing task: cargo test --doc --package my_crate -- quax::Bar::baz --nocapture
...
running 1 test
test src\lib.rs - quax::Bar::baz (line 1246) ... ok
...

created time in 13 days

PR opened rust-analyzer/rust-analyzer

Use a flat play icon instead of the blue emoji with test code lens

@lnicola

Restores this commit: https://github.com/rust-analyzer/rust-analyzer/commit/55e914a2a179aba63bd9948d6e0cf3e2a4bf5960

That was effectively wiped out by this code formatting commit: https://github.com/rust-analyzer/rust-analyzer/commit/dc217bdf90d555eaa1780041fc3a14e64173994d https://github.com/rust-analyzer/rust-analyzer/commit/3d445256fe56f4a7ead64514fb57b79079973d84

+2 -2

0 comment

1 changed file

pr created time in 13 days

create barnchaloucks/rust-analyzer

branch : no_emoji

created branch time in 13 days

fork aloucks/rust-analyzer

An experimental Rust compiler front-end for IDEs

https://rust-analyzer.github.io/

fork in 13 days

push eventaloucks/directx_math

Aaron Loucks

commit sha ccc6635205f109d8438fa700e4e8263949887637

Update description

view details

Aaron Loucks

commit sha 0d39d793afa747fa49fb4ce1c6adf902ac5d79f4

Doc updates

view details

push time in 14 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 6634080e576ba598d33b127c5dde337cc72e7262

Update description

view details

push time in 14 days

created tagaloucks/directx_math

tagv0.1.0-alpha.5

DirectXMath for Rust

created time in 14 days

push eventaloucks/directx_math

Aaron Loucks

commit sha c8ab4357ff520e3d20712e46f28f2909b55c201d

Version v0.1.0-alpha.5

view details

push time in 14 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 5fce4b5e2125e5606e8d34741a09aa72d036892b

Add AsMut and AsRef impls

view details

Aaron Loucks

commit sha 12c8ade070a93b814e8d2abbe82699e52af53f00

Remove dead placeholder code, replaced by Align16

view details

push time in 14 days

pull request commentSaschaWillems/vulkan.gpuinfo.org

Fix device limit page header

@SaschaWillems can this be merged?

krOoze

comment created time in 15 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 833ca4bba780f7f87a9dc7538fc8f4ba460dd275

Rename _MM_SHUFFLE args to match xmmintrin.h

view details

Aaron Loucks

commit sha 151a20c8133fcbc3ed24b03d93f7ed884ecb3457

Use inline(always) on simple conversion and comparison functions

view details

Aaron Loucks

commit sha 0a32df85f1c882af1318eee92f9254a4a52a26e5

Fix documentation for XMVectorIsInfinite

view details

push time in 15 days

Pull request review commentrust-windowing/winit

Experiment with an improved event design

 pub enum WindowEvent<'a> {     ///     /// When the user drops multiple files at once, this event will be emitted for each file     /// separately.-    DroppedFile(PathBuf),+    FileDropped(PathBuf),      /// A file is being hovered over the window.     ///     /// When the user hovers multiple files at once, this event will be emitted for each file     /// separately.-    HoveredFile(PathBuf),+    FileHovered(PathBuf),      /// A file was hovered, but has exited the window.     ///     /// There will be a single `HoveredFileCancelled` event triggered even if multiple files were     /// hovered.-    HoveredFileCancelled,+    FileHoverCancelled,++    /// The window gained focus.+    FocusGained,++    /// The window lost focus.+    FocusLost,      /// The window received a unicode character.-    ReceivedCharacter(char),+    CharReceived(char), -    /// The window gained or lost focus.-    ///-    /// The parameter is true if the window has gained focus, and false if it has lost focus.-    Focused(bool),--    /// An event from the keyboard has been received.-    KeyboardInput {-        device_id: DeviceId,-        input: KeyboardInput,-        /// If `true`, the event was generated synthetically by winit-        /// in one of the following circumstances:-        ///-        /// * Synthetic key press events are generated for all keys pressed-        ///   when a window gains focus. Likewise, synthetic key release events-        ///   are generated for all keys pressed when a window goes out of focus.-        ///   ***Currently, this is only functional on X11 and Windows***-        ///-        /// Otherwise, this value is always `false`.-        is_synthetic: bool,-    },+    KeyPress(KeyPress),

KeyPress is rather synonymous with "down", while Release is thought of as "up". Perhaps this should just be named Key ?

Osspial

comment created time in 16 days

Pull request review commentrust-windowing/winit

Experiment with an improved event design

 pub enum WindowEvent<'a> {     /// hovered.     HoveredFileCancelled, +    /// The window gained focus.+    FocusedGained,++    /// The window lost focus.+    FocustLost,+     /// The window received a unicode character.-    ReceivedCharacter(char),+    Char(char), -    /// The window gained or lost focus.-    ///-    /// The parameter is true if the window has gained focus, and false if it has lost focus.-    Focused(bool),--    /// An event from the keyboard has been received.-    KeyboardInput {-        device_id: DeviceId,-        input: KeyboardInput,-        /// If `true`, the event was generated synthetically by winit-        /// in one of the following circumstances:-        ///-        /// * Synthetic key press events are generated for all keys pressed-        ///   when a window gains focus. Likewise, synthetic key release events-        ///   are generated for all keys pressed when a window goes out of focus.-        ///   ***Currently, this is only functional on X11 and Windows***-        ///-        /// Otherwise, this value is always `false`.-        is_synthetic: bool,-    },+    KeyPress(KeyPress),      /// The keyboard modifiers have changed.     ///+    /// This is tracked internally to avoid tracking errors arising from modifier key state changes when events from+    /// this device are not being delivered to the application, e.g. due to keyboard focus being elsewhere.+    ///     /// Platform-specific behavior:     /// - **Web**: This API is currently unimplemented on the web. This isn't by design - it's an     ///   issue, and it should get fixed - but it's the current state of the API.     ModifiersChanged(ModifiersState), -    /// The cursor has moved on the window.-    CursorMoved {-        device_id: DeviceId,+    PointerCreated(PointerId),+    PointerDestroyed(PointerId), -        /// (x,y) coords in pixels relative to the top-left corner of the window. Because the range of this data is-        /// limited by the display area and it may have been transformed by the OS to implement effects such as cursor-        /// acceleration, it should not be used to implement non-cursor-like interactions such as 3D camera control.-        position: PhysicalPosition<f64>,-        #[deprecated = "Deprecated in favor of WindowEvent::ModifiersChanged"]-        modifiers: ModifiersState,-    },+    PointerMoved(PointerId, PhysicalPosition<f64>), -    /// The cursor has entered the window.-    CursorEntered { device_id: DeviceId },+    PointerEntered(PointerId),+    PointerLeft(PointerId), -    /// The cursor has left the window.-    CursorLeft { device_id: DeviceId },+    PointerForce(PointerId, Force), -    /// A mouse wheel movement or touchpad scroll occurred.-    MouseWheel {-        device_id: DeviceId,-        delta: MouseScrollDelta,-        phase: TouchPhase,-        #[deprecated = "Deprecated in favor of WindowEvent::ModifiersChanged"]-        modifiers: ModifiersState,-    },+    PointerPress(PointerId, PointerPress), -    /// An mouse button press has been received.-    MouseInput {-        device_id: DeviceId,-        state: ElementState,-        button: MouseButton,-        #[deprecated = "Deprecated in favor of WindowEvent::ModifiersChanged"]-        modifiers: ModifiersState,-    },+    ScrollStarted,+    ScrollDiscrete(Vector<i32>),+    ScrollSmooth(Vector<f64>),+    ScrollEnded, -    /// Touchpad pressure event.+    /// The system window theme has changed.     ///-    /// At the moment, only supported on Apple forcetouch-capable macbooks.-    /// The parameters are: pressure level (value between 0 and 1 representing how hard the touchpad-    /// is being pressed) and stage (integer representing the click level).-    TouchpadPressure {-        device_id: DeviceId,-        pressure: f32,-        stage: i64,-    },+    /// Applications might wish to react to this to change the theme of the content of the window+    /// when the system changes the window theme.+    ///+    /// At the moment this is only supported on Windows.+    ThemeChanged(Theme),+} -    /// Motion on some analog axis. May report data redundant to other, more specific events.-    AxisMotion {-        device_id: DeviceId,-        axis: AxisId,-        value: f64,-    },+#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash, PartialOrd, Ord)]+#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]+pub struct Vector<T> {+    pub x: T,+    pub y: T,+}++#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash, PartialOrd, Ord)]+pub struct KeyPress {+    pub(crate) logical_key: Option<LogicalKey>,+    pub(crate) scan_code: u32,+    pub(crate) is_down: bool,+    pub(crate) repeat_count: u32,+    pub(crate) is_synthetic: bool,+}++#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash, PartialOrd, Ord)]+pub struct RawKeyPress {+    pub(crate) logical_key: Option<LogicalKey>,+    pub(crate) scan_code: u32,+    pub(crate) is_down: bool,+}++#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash, PartialOrd, Ord)]+pub struct PointerPress {+    pub(crate) button: u8,+    pub(crate) is_down: bool,+    pub(crate) click_count: u32,+} -    /// Touch event has been received-    Touch(Touch),+#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash, PartialOrd, Ord)]+pub struct RawPointerPress {+    pub(crate) button: u8,+    pub(crate) is_down: bool,

these events don't and shouldn't have public constructors.

Testing event handling will become impossible if you can't create the event structures.

Osspial

comment created time in 16 days

startedwalbourn/directxmathtest

started time in 16 days

issue commentrust-lang/stdarch

_MM_SHUFFLE has incorrect return type

The arguments should probably also be renamed to match xmmintrin.h.

pub fn _MM_SHUFFLE(z: u32, y: u32, x: u32, w: u32) -> i32
#define _MM_SHUFFLE(fp3,fp2,fp1,fp0) \
 (((fp3) << 6) | ((fp2) << 4) | ((fp1) << 2) | (fp0))
Paul-E

comment created time in 17 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 4023b0e8de1441965a09169b6c46d8fac3bd3e6e

Added align load/store for vec3/4 and matrix - Changed XMVector PartialEq impl to use XMVector4Equal instead of XMVector4NearEqual. - Unsealed Permute and Swizzle traits - Documentation updates

view details

push time in 17 days

issue commentrust-analyzer/rust-analyzer

Proposal: color attributes using regular syntax coloring

IntelliJs highlighting does something similar (note that Debug is highlighted as a trait):

image

georgewfraser

comment created time in 21 days

issue commentrust-analyzer/rust-analyzer

Proposal: color attributes using regular syntax coloring

I use an older version of atom one dark and currently have semantic coloring turned off until it gets sorted out a bit more.

I suspect that the changes proposed here might break existing themes that already have support for rust. I'm curious what would happen if you added the additional scopes but do not remove any of the existing ones.

image

image

image

georgewfraser

comment created time in 21 days

pull request commentrust-analyzer/rust-analyzer

Enhanced coloring

Why wouldn't attributes use meta.attribute.rust? Wouldn't this change remove the ability to color attributes different from keywords?

georgewfraser

comment created time in 22 days

push eventaloucks/vki

Aaron Loucks

commit sha e4df1dde6a74887aff4d3ca5bd6b7722e2b72470

Update ash to 0.31

view details

push time in 22 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 88a1571c70cddc6619b2f2b8f47f2c9c03527281

Update more scalar docs

view details

push time in 22 days

push eventaloucks/directx_math

Aaron Loucks

commit sha a0464dc94b5ed9f6ed2596b499171f4330e063aa

Update more scalar docs

view details

push time in 22 days

push eventaloucks/directx_math

Aaron Loucks

commit sha f2db8360b90ba6af225fb041c298286daeced9e0

Version v0.1.0-alpha.4

view details

push time in 22 days

created tagaloucks/directx_math

tagv0.1.0-alpha.4

DirectXMath for Rust

created time in 22 days

push eventaloucks/directx_math

Aaron Loucks

commit sha 242d9378a299a542cfe7989359bd302ef9543b6c

Vector documentation updates

view details

push time in 22 days

pull request commentrust-analyzer/rust-analyzer

Textmate cooperation

I think & looks weird now that it's the same color as self (and presumable mut as well). I think & looks better uncolored/grey.

georgewfraser

comment created time in 23 days

issue commentrust-lang/rust

rustdoc: some trait methods appear as "hidden undocumented items"

The generated rustdocs seem to have regressed over the past few years.

For example the cgmath Point3 docs from January of 2019 have the traits expanded by default and the traits from the crate seem to be sorted to the top:

image

Today, there there appears to be more traits referenced in the docs but nothing is expanded and finding the traits from the crate is difficult:

image

(Scrolling all the way down....)

image

eminence

comment created time in 23 days

more