File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ mod sealed {
1111 use stmt:: Column ;
1212
1313 pub trait Sealed {
14- fn idx ( & self , stmt : & [ Column ] ) -> Option < usize > ;
14+ fn __idx ( & self , stmt : & [ Column ] ) -> Option < usize > ;
1515 }
1616}
1717
@@ -22,7 +22,7 @@ pub trait RowIndex: Sealed {}
2222
2323impl Sealed for usize {
2424 #[ inline]
25- fn idx ( & self , stmt : & [ Column ] ) -> Option < usize > {
25+ fn __idx ( & self , stmt : & [ Column ] ) -> Option < usize > {
2626 if * self >= stmt. len ( ) {
2727 None
2828 } else {
@@ -35,7 +35,7 @@ impl RowIndex for usize {}
3535
3636impl Sealed for str {
3737 #[ inline]
38- fn idx ( & self , stmt : & [ Column ] ) -> Option < usize > {
38+ fn __idx ( & self , stmt : & [ Column ] ) -> Option < usize > {
3939 if let Some ( idx) = stmt. iter ( ) . position ( |d| d. name ( ) == self ) {
4040 return Some ( idx) ;
4141 } ;
5656 T : ?Sized + Sealed ,
5757{
5858 #[ inline]
59- fn idx ( & self , columns : & [ Column ] ) -> Option < usize > {
60- T :: idx ( * self , columns)
59+ fn __idx ( & self , columns : & [ Column ] ) -> Option < usize > {
60+ T :: __idx ( * self , columns)
6161 }
6262}
6363
Original file line number Diff line number Diff line change @@ -225,7 +225,7 @@ impl<'a> Row<'a> {
225225 I : RowIndex ,
226226 T : FromSql ,
227227 {
228- let idx = match idx. idx ( & self . stmt_info . columns ) {
228+ let idx = match idx. __idx ( & self . stmt_info . columns ) {
229229 Some ( idx) => idx,
230230 None => return None ,
231231 } ;
@@ -247,7 +247,7 @@ impl<'a> Row<'a> {
247247 where
248248 I : RowIndex + fmt:: Debug ,
249249 {
250- match idx. idx ( & self . stmt_info . columns ) {
250+ match idx. __idx ( & self . stmt_info . columns ) {
251251 Some ( idx) => self . data . get ( idx) ,
252252 None => panic ! ( "invalid index {:?}" , idx) ,
253253 }
Original file line number Diff line number Diff line change @@ -69,7 +69,7 @@ impl Row {
6969 T : FromSql ,
7070 I : RowIndex ,
7171 {
72- let idx = match idx. idx ( & self . columns ) {
72+ let idx = match idx. __idx ( & self . columns ) {
7373 Some ( idx) => idx,
7474 None => return Ok ( None ) ,
7575 } ;
You can’t perform that action at this time.
0 commit comments