Skip to content

Commit 1038a6f

Browse files
authored
Remove duplicate re-export of Model macro (Azure#1864)
Also re-exports `Model` from `azure_core` along with some other types that were exported from the crate root in track 1.
1 parent 8a12d75 commit 1038a6f

File tree

4 files changed

+7
-10
lines changed

4 files changed

+7
-10
lines changed

sdk/core/azure_core/src/lib.rs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ pub use models::*;
3838
pub use options::*;
3939
pub use pipeline::*;
4040
pub use policies::*;
41-
pub use typespec_client_core::http::response::{Model, PinnedStream, Response, ResponseBody};
4241

4342
// Re-export typespec types that are not specific to Azure.
4443
pub use typespec::{Error, Result};
@@ -51,8 +50,11 @@ pub use typespec_client_core::xml;
5150
pub use typespec_client_core::{
5251
base64, date,
5352
http::{
54-
headers::Header, new_http_client, AppendToUrlQuery, Body, Context, HttpClient, Method,
55-
Pager, Request, RequestContent, StatusCode, Url,
53+
headers::Header,
54+
new_http_client,
55+
response::{Model, PinnedStream, Response, ResponseBody},
56+
AppendToUrlQuery, Body, Context, HttpClient, Method, Pager, Request, RequestContent,
57+
StatusCode, Url,
5658
},
5759
json, parsing,
5860
sleep::{self, sleep},

sdk/identity/azure_identity/src/federated_credentials_flow/response.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,9 @@
33

44
#![allow(dead_code)]
55

6-
use azure_core::credentials::Secret;
6+
use azure_core::{credentials::Secret, Model};
77
use serde::{Deserialize, Deserializer};
88
use time::OffsetDateTime;
9-
use typespec_client_core::Model;
109

1110
#[derive(Debug, Clone, Deserialize)]
1211
struct RawLoginResponse {

sdk/identity/azure_identity/src/refresh_token.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,11 @@ use azure_core::{
99
error::{http_response_from_body, Error, ErrorKind, ResultExt},
1010
headers,
1111
json::from_json,
12-
HttpClient, Method, Request, Url,
12+
HttpClient, Method, Model, Request, Url,
1313
};
1414
use serde::Deserialize;
1515
use std::fmt;
1616
use std::sync::Arc;
17-
use typespec_client_core::Model;
1817
use url::form_urlencoded;
1918

2019
/// Exchange a refresh token for a new access token and refresh token.

sdk/typespec/typespec_client_core/src/lib.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,3 @@ pub mod xml;
2121
pub use crate::error::{Error, Result};
2222
pub use bytes::Bytes;
2323
pub use uuid::Uuid;
24-
25-
#[cfg(feature = "derive")]
26-
pub use typespec_derive::Model;

0 commit comments

Comments
 (0)