Skip to content

Commit 0f2cd2e

Browse files
authored
Add 'pub' and '#[pyo3(get, set)]' to DataTypeMap (apache#371)
1 parent 4175134 commit 0f2cd2e

1 file changed

Lines changed: 7 additions & 7 deletions

File tree

‎src/common/data_type.rs‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,12 @@ use crate::errors::py_datafusion_err;
3333
#[derive(Debug, Clone)]
3434
#[pyclass(name = "DataTypeMap", module = "datafusion.common", subclass)]
3535
pub struct DataTypeMap {
36-
#[allow(dead_code)]
37-
arrow_type: PyDataType,
38-
#[allow(dead_code)]
39-
python_type: PythonType,
40-
#[allow(dead_code)]
41-
sql_type: SqlType,
36+
#[pyo3(get, set)]
37+
pub arrow_type: PyDataType,
38+
#[pyo3(get, set)]
39+
pub python_type: PythonType,
40+
#[pyo3(get, set)]
41+
pub sql_type: SqlType,
4242
}
4343

4444
impl DataTypeMap {
@@ -421,7 +421,7 @@ impl DataTypeMap {
421421
#[derive(Debug, Clone, PartialEq, Eq, Hash, PartialOrd, Ord)]
422422
#[pyclass(name = "DataType", module = "datafusion.common")]
423423
pub struct PyDataType {
424-
data_type: DataType,
424+
pub data_type: DataType,
425425
}
426426

427427
impl From<PyDataType> for DataType {

0 commit comments

Comments
 (0)