Skip to content
Permalink
Browse files

Allow dots in variant names

  • Loading branch information
raimue committed Mar 12, 2018
1 parent bc58fe8 commit c3f08731079670d5be809a22a4fae62acd8f8555
Showing with 4 additions and 4 deletions.
  1. +2 −2 src/port1.0/portlint.tcl
  2. +2 −2 src/port1.0/portutil.tcl
@@ -437,8 +437,8 @@ proc portlint::lint_main {args} {
set name_ok true
set desc_ok true

if {![regexp {^[A-Za-z0-9_]+$} $variantname]} {
ui_error "Variant name $variantname is not valid; use \[A-Za-z0-9_\]+ only"
if {![regexp {^[A-Za-z0-9_.]+$} $variantname]} {
ui_error "Variant name $variantname is not valid; use \[A-Za-z0-9_.\]+ only"
incr errors
set name_ok false
}
@@ -590,7 +590,7 @@ proc variant {args} {
}
ditem_key $ditem name "[join [ditem_key $ditem provides] -]"

if {![regexp {^[A-Za-z0-9_]+$} [ditem_key $ditem provides]]} {
if {![regexp {^[A-Za-z0-9_.]+$} [ditem_key $ditem provides]]} {
set name [ditem_key $ditem provides]
ditem_delete $ditem
return -code error "Variant name $name contains invalid characters"
@@ -2223,7 +2223,7 @@ proc handle_default_variants {option action {value ""}} {
}
array set vinfo $PortInfo(vinfo)
foreach v $value {
if {[regexp {([-+])([-A-Za-z0-9_]+)} $v whole val variant]} {
if {[regexp {([-+])([-A-Za-z0-9_.]+)} $v whole val variant]} {
# Retrieve the information associated with this variant.
if {![info exists vinfo($variant)]} {
set vinfo($variant) {}

0 comments on commit c3f0873

Please sign in to comment.
You can’t perform that action at this time.