Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft: Add dependencies to copyright file #3

Closed

Conversation

jonathanpallant
Copy link

Adds cargo dependencies to the file COPYRIGHT.md file generated by x run generate-copyright.

Don't merge here - it needs to go upstream.

src/tools/generate-copyright/src/cargo_metadata.rs Outdated Show resolved Hide resolved
src/tools/generate-copyright/src/licenses.rs Outdated Show resolved Hide resolved
src/tools/generate-copyright/src/main.rs Outdated Show resolved Hide resolved
src/tools/generate-copyright/src/main.rs Outdated Show resolved Hide resolved
@jonathanpallant
Copy link
Author

Changes made as requested.

@jonathanpallant jonathanpallant force-pushed the jonathanpallant/add-dependencies-to-copyright-file branch from 7c0ac2e to 2fcd2fc Compare July 10, 2024 09:00
@jonathanpallant
Copy link
Author

Now with HTML output

@jonathanpallant
Copy link
Author

Squashed and rebased.

@jonathanpallant jonathanpallant force-pushed the jonathanpallant/add-dependencies-to-copyright-file branch from 09c09f8 to dd2de6d Compare July 29, 2024 10:43
matthiaskrgr and others added 18 commits August 1, 2024 08:33
…e-revs, r=jieyouxu

Ignore `use` declaration reformatting in `.git-blame-ignore-revs`.

The reformatting was done in rust-lang#125443.

r? `@lcnr`
…iaskrgr

Rollup of 6 pull requests

Successful merges:

 - rust-lang#128416 (android: Remove libstd hacks for unsupported Android APIs)
 - rust-lang#128437 (improve bootstrap to allow selecting llvm tools individually)
 - rust-lang#128450 (Create COFF archives for non-LLVM backends)
 - rust-lang#128458 (Emit an error if `#[optimize]` is applied to an incompatible item)
 - rust-lang#128477 (Finish blessing `coverage/mcdc` tests after LLVM 19 upgrade)
 - rust-lang#128478 (Ignore `use` declaration reformatting in `.git-blame-ignore-revs`.)

r? `@ghost`
`@rustbot` modify labels: rollup
docs: Fix JSON example for rust-analyzer.workspace.discoverConfig

The user does not specify `{arg}` in their JSON, and be pedantic about commas in JSON sample.
It can be done more concisely.
When collecting tokens there are two kinds of range:
- a range relative to the parser's full token stream (which we get when
  we are parsing);
- a range relative to a single AST node's token stream (which we use
  within `LazyAttrTokenStreamImpl` when replacing tokens).

These are currently both represented with `Range<u32>` and it's easy to
mix them up -- until now I hadn't properly understood the difference.

This commit introduces `ParserRange` and `NodeRange` to distinguish
them. This also requires splitting `ReplaceRange` in two, giving the new
types `ParserReplacement` and `NodeReplacement`. (These latter two names
reduce the overloading of the word "range".)

The commit also rewrites some comments to be clearer.

The end result is a little more verbose, but much clearer.
when josh-proxy screws up the roundtrip, say what the involved commits are
when josh-proxy screws up the roundtrip, say what the involved commits are

Helps debugging rust-lang/rust-analyzer#17733
…ication, r=estebank,traviscross

More unsafe attr verification

This code denies unsafe on attributes such as `#[test]` and `#[ignore]`, while also changing the `MetaItem` parsing so `unsafe` in args like `#[allow(unsafe(dead_code))]` is not accidentally allowed.

Tracking:

- rust-lang#123757
bors and others added 26 commits August 5, 2024 17:28
use a Miri-specific folder for ui tests
bump dependencies

In particular pick up RalfJung/rustc-build-sysroot#22 to fix the fallout from rust-lang#128534.
…-Simulacrum

Promote riscv64gc-unknown-linux-musl to tier 2
Use `ParamEnv::reveal_all` in CFI

I left a huge comment for why this ICEs in the test I committed.

`typeid_for_instance` should only be called on monomorphic instances during codegen, and we should just be using `ParamEnv::reveal_all()` rather than the param-env of the instance itself. I added an assertion to ensure that we only do this for fully substituted instances (this may break with polymorphization, but I kinda don't care lol).

Fixes rust-lang#114160
cc `@rcvalle`
…compiler-errors

custom MIR: add support for tail calls

Cc ``@WaffleLapkin``
Normalize when equating `dyn` tails in MIR borrowck

See the explanation in the comment.

Fixes rust-lang#128621
cc `@WaffleLapkin`
…rors

interpret: move nullary-op evaluation into operator.rs

We call it an operator, so we might as well treat it like one. :)

Also use more consistent naming for the "evaluate intrinsic" functions. "emulate" is really the wrong term, this *is* a genuine implementation of the intrinsic semantics after all.
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#122049 (Promote riscv64gc-unknown-linux-musl to tier 2)
 - rust-lang#128580 (Use `ParamEnv::reveal_all` in CFI)
 - rust-lang#128688 (custom MIR: add support for tail calls)
 - rust-lang#128694 (Normalize when equating `dyn` tails in MIR borrowck)
 - rust-lang#128697 (interpret: move nullary-op evaluation into operator.rs)

r? `@ghost`
`@rustbot` modify labels: rollup
Tweak type inference for `const` operands in inline asm

Previously these would be treated like integer literals and default to `i32` if a type could not be determined. To allow for forward-compatibility with `str` constants in the future, this PR changes type inference to use an unbound type variable instead.

The actual type checking is deferred until after typeck where we still ensure that the final type for the `const` operand is an integer type.

<!--
If this PR is related to an unstable feature or an otherwise tracked effort,
please link to the relevant tracking issue here. If you don't know of a related
tracking issue or there are none, feel free to ignore this.

This PR will get automatically assigned to a reviewer. In case you would like
a specific user to review your work, you can assign it to them by using

    r​? <reviewer name>
-->
…felix

Change output normalization logic to be linear against size of output

Modify the rendered output normalization routine to scan each character *once* and construct a `String` to be printed out to the terminal *once*, instead of using `String::replace` in a loop multiple times. The output doesn't change, but the time spent to prepare a diagnostic is now faster (or rather, closer to what it was before rust-lang#127528).
The `error-format=short` output only displays the path, error code and
main error message all in the same line. We now add the primary span label
as well after the error message, to provide more context.
…r=davidtwco

On short error format, append primary span label to message

The `error-format=short` output only displays the path, error code and main error message all in the same line. We now add the primary span label as well after the error message, to provide more context.
This tool now scans for cargo dependencies and includes any important looking license files.

We do this because cargo package metadata is not sufficient - the Apache-2.0 license says you have to include any NOTICE file, for example. And authors != copyright holders (cargo has the former, we must include the latter).
This format works better with large amounts of structured data.

We also mark which deps are in the stdlib
I can't find a way to derive rinja::Template for Node - I think because it is a recursive type. So I rendered it manually using html_escape.
@jonathanpallant jonathanpallant force-pushed the jonathanpallant/add-dependencies-to-copyright-file branch from 6382c17 to 4e24e9b Compare August 6, 2024 11:04
@jonathanpallant
Copy link
Author

Merged upstream as rust-lang#128353

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.