File tree Expand file tree Collapse file tree 2 files changed +8
-9
lines changed Expand file tree Collapse file tree 2 files changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -1762,11 +1762,14 @@ impl<P: ResolveToPath> DetailedTomlDependency<P> {
1762
1762
kind : Option < DepKind > ,
1763
1763
) -> CargoResult < Dependency > {
1764
1764
if self . version . is_none ( ) && self . path . is_none ( ) && self . git . is_none ( ) {
1765
- bail ! (
1765
+ let msg = format ! (
1766
1766
"dependency ({}) specified without \
1767
- providing a local path, Git repository, or version to use.",
1767
+ providing a local path, Git repository, or \
1768
+ version to use. This will be considered an \
1769
+ error in future versions",
1768
1770
name_in_toml
1769
1771
) ;
1772
+ cx. warnings . push ( msg) ;
1770
1773
}
1771
1774
1772
1775
if let Some ( version) = & self . version {
Original file line number Diff line number Diff line change @@ -763,14 +763,10 @@ fn empty_dependencies() {
763
763
Package :: new ( "bar" , "0.0.1" ) . publish ( ) ;
764
764
765
765
p. cargo ( "build" )
766
- . with_status ( 101 )
767
- . with_stderr (
766
+ . with_stderr_contains (
768
767
"\
769
- [ERROR] failed to parse manifest at `[..]`
770
-
771
- Caused by:
772
- dependency (bar) specified without providing a local path, Git repository, or version \
773
- to use.
768
+ warning: dependency (bar) specified without providing a local path, Git repository, or version \
769
+ to use. This will be considered an error in future versions
774
770
" ,
775
771
)
776
772
. run ( ) ;
You can’t perform that action at this time.
0 commit comments