Pricefield | Lemmy
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
brokenix to Rust [email protected] •
edit-2
11 months ago

[\#rust](https://emacs.ch/tags/rust) folks it's supposed to throw this error without lazy_static crate , but it doesn't?

message-square
4
fedilink
1
message-square

[\#rust](https://emacs.ch/tags/rust) folks it's supposed to throw this error without lazy_static crate , but it doesn't?

brokenix to Rust [email protected] •
edit-2
11 months ago
message-square
4
fedilink

#rust folks it’s supposed to throw this error without lazy_static crate , but it doesn’t?
https://git.sr.ht/~carnotweat/morning-rust/tree/main/item/sum.rs#L14
cc @rust @learningrustandlemmy

  • brokenixOP
    link
    fedilink
    1•
    edit-2
    11 months ago

    @rust @learningrustandlemmy
    I might have missed some subtle syntactical difference here, I guess
    aas in Vec<...> is a type definition, and Vec::<...> is referring to the struct itself, but with a type parameter given.
    context - https://www.reddit.com/r/learnrust/comments/exmqyc/what_are_the_rules_for_turbofish/

Rust [email protected]

[email protected]
Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: [email protected]
  • 2 users / day
  • 1 user / week
  • 16 users / month
  • 89 users / 6 months
  • 3 subscribers
  • 275 Posts
  • 912 Comments
  • Modlog
  • mods:
  • @[email protected]
  • @[email protected]
  • Nutomic
  • UI: 0.18.4
  • BE: 0.18.2
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org