11# File src/library/base/R/seq.R
22# Part of the R package, https://www.R-project.org
33#
4- # Copyright (C) 1995-2021 The R Core Team
4+ # Copyright (C) 1995-2025 The R Core Team
55#
66# This program is free software; you can redistribute it and/or modify
77# it under the terms of the GNU General Public License as published by
@@ -37,7 +37,7 @@ seq.default <-
3737 }
3838 else if (! missing(length.out )) {
3939 len <- length(length.out )
40- if (! len ) stop(" argument 'length.out ' must be of length 1" )
40+ if (! len ) stop(gettextf( " '%s ' must be of length 1" , " length.out " ), domain = NA )
4141 if (len > 1L ) {
4242 warning(" first element used of 'length.out' argument" )
4343 length.out <- length.out [1L ]
@@ -46,8 +46,8 @@ seq.default <-
4646 length.out <- as.numeric(ceiling(length.out ))
4747 }
4848 chkDots(... )
49- if (! missing(from ) && length(from ) != 1L ) stop(" 'from ' must be of length 1" )
50- if (! missing(to ) && length(to ) != 1L ) stop(" 'to ' must be of length 1" )
49+ if (! missing(from ) && length(from ) != 1L ) stop(gettextf( " '%s ' must be of length 1" , " from " ), domain = NA )
50+ if (! missing( to ) && length( to ) != 1L ) stop(gettextf( " '%s ' must be of length 1" , " to " ), domain = NA )
5151 if (! missing(from ) && # For seq("2","5") but not breaking seq(to=1, from=as.Date(.)):
5252 ! is.finite(if (is.character(from )) from <- as.numeric(from ) else from ))
5353 stop(" 'from' must be a finite number" )
@@ -61,7 +61,7 @@ seq.default <-
6161 int <- is.logint(from ) && is.logint(to )
6262 del <- to - if (int ) as.double(from ) else from
6363 if (del == 0 && to == 0 ) return (to )
64- if (length(by ) != 1L ) stop(" 'by ' must be of length 1" )
64+ if (length(by ) != 1L ) stop(gettextf( " '%s ' must be of length 1" , " by " ), domain = NA )
6565 if (! is.logint(by ))
6666 int <- FALSE
6767 else if (! int )
0 commit comments