{"push_id":645769179,"size":9,"distinct_size":0,"ref":"refs/heads/auto","head":"857ef6e272e5634cb9f3e6ee50eb6bc2a2e71651","before":"32f9f4276271bac1b8c3bc569ceed5cfaf992f29","commits":[{"sha":"b5499775d6bee080b3f46539d59d238de2c1726f","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Structural changes for associated constants\n\nIntroduces new variants and types in syntax::ast, middle::ty, and middle::def.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/b5499775d6bee080b3f46539d59d238de2c1726f"},{"sha":"7129e8815e3203ceae5bb85b0faa8e8753e520e3","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Functional changes for associated constants. Cross-crate usage of associated constants is not yet working.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/7129e8815e3203ceae5bb85b0faa8e8753e520e3"},{"sha":"3d9b5d04242567648800c5594695f147c6bca05b","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Fix a number of bugs that interfered with cross-crate usage of associated consts.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/3d9b5d04242567648800c5594695f147c6bca05b"},{"sha":"7f7888754745696467d6ba8f93ce2b9e50c10b3b","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Add previously omitted associated const tests.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/7f7888754745696467d6ba8f93ce2b9e50c10b3b"},{"sha":"91ae5e31ab57de15ef2855c700ad4b012ea00234","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Fix dead code check for associated const impls.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/91ae5e31ab57de15ef2855c700ad4b012ea00234"},{"sha":"29eb550ee6a9fd6961bb00e2680a5735aab95de1","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Get associated consts working in match patterns.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/29eb550ee6a9fd6961bb00e2680a5735aab95de1"},{"sha":"b1db4ec3d0a96a1e83d74fbc7f99dc3be054f4d8","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Feature-gate associated constants.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/b1db4ec3d0a96a1e83d74fbc7f99dc3be054f4d8"},{"sha":"4c0ac6d5ef8aed2cbe0cc687d5e7f8a8c04961a3","author":{"email":"5a7997baeb049019bc018c70dd79ed5df07d8b0b@gmail.com","name":"Sean Patrick Santos"},"message":"Remove obsolete \"MarkerTrait\" from tests.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/4c0ac6d5ef8aed2cbe0cc687d5e7f8a8c04961a3"},{"sha":"857ef6e272e5634cb9f3e6ee50eb6bc2a2e71651","author":{"email":"3a2c29237f73c7cf88424b80e427b1884f346b35@rust-lang.org","name":"bors"},"message":"Auto merge of #23606 - quantheory:associated_const, r=nikomatsakis\n\nCloses #17841.\r\n\r\nThe majority of the work should be done, e.g. trait and inherent impls, different forms of UFCS syntax, defaults, and cross-crate usage. It's probably enough to replace the constants in `f32`, `i8`, and so on, or close to good enough.\r\n\r\nThere is still some significant functionality missing from this commit:\r\n\r\n - ~~Associated consts can't be used in match patterns at all. This is simply because I haven't updated the relevant bits in the parser or `resolve`, but it's *probably* not hard to get working.~~\r\n - Since you can't select an impl for trait-associated consts until partway through type-checking, there are some problems with code that assumes that you can check constants earlier. Associated consts that are not in inherent impls cause ICEs if you try to use them in array sizes or match ranges. For similar reasons, `check_static_recursion` doesn't check them properly, so the stack goes ka-blooey if you use an associated constant that's recursively defined. That's a bit trickier to solve; I'm not entirely sure what the best approach is yet.\r\n - Dealing with consts associated with type parameters will raise some new issues (e.g. if you have a `T: Int` type parameter and want to use `<T>::ZERO`). See rust-lang/rfcs#865.\r\n - ~~Unused associated consts don't seem to trigger the `dead_code` lint when they should. Probably easy to fix.~~\r\n\r\nAlso, this is the first time I've been spelunking in rustc to such a large extent, so I've probably done some silly things in a couple of places.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/857ef6e272e5634cb9f3e6ee50eb6bc2a2e71651"}]}